vendredi 16 février 2018

Change code by looking to url slug

Im trying to place a image under the topic categorie, here is a screendump of my homepage, you see 6 diffrent categories, this is a static homepage with images and href to new page categories. So not realy exciting. But......

After that, the categories will be generated from the dtb, so there is no static page for. When you click on the image on home you will go to the categorie like you see here.

I tried to make a custom field with ACF and create a settings page with Pods, but unfortunately everytime I post a new topic to the categorie I should include the categorie image.

I think it can be done in a better way, but for now I thought on this solution maybe I can place some code with if url ends with /topic/websites/ load this and if the url ends on /topic/support/ load this part of code.

Probaly i'm not the first one that asks some familiar question like this but I couldt find this question on Stack, sorry for double post then.

Thanks for any help, hope someone can put me in the right direction.

Aucun commentaire:

Enregistrer un commentaire