gilescarey
Member
Posted 3 years ago #
Hi
I am looking to do something which I thought was quite simple. I am looking to basically have the visitor visit a category page.
If there are subcategories to the category they are looking at, then a list of links to the relevant subcategory pages should be displayed.
If not, then nothing needs to done, just show all posts under that category - surely that shouldn't be so hard!
Thanks in advance.
Not hard at all. Use the $cat = get_query_var('cat'); to get the current category, then use the template tag, wp_list_categories(), with the child_of argument.
leckley
Member
Posted 3 years ago #
Hi,
Would you be able to give a little more info on how to accomplish this? Not a programmer here, thanks!
pickledlove
Member
Posted 2 years ago #
leckley, did you ever get this figured out? I have the same question.
jenscento
Member
Posted 2 years ago #
Did anyone get this working?