Access our premium support and let us know your problems, we will help you solve them.

0
No products in the cart.

Forum Replies Created

Viewing 1 post (of 1 total)
  • Author
    Posts
  • in reply to: Get current category ID of the active page #9533
    blankbill
    Participant

    I found this question whilst looking for exactly what you asked. Unfortunately you have accepted an incorrect answer. For the sake of other people who are trying to achieve what we were trying to achieve, I thought I’d post the correct answer.

    $cur_cat = get_cat_ID( single_cat_title("",false) );
    

    As you said single_term_title("", false); was correctly returning the category title, I’m not sure why you would have had troubles with your code; but the above code works flawlessly for me.

Viewing 1 post (of 1 total)