PHP within PHP – How to use get_template_part with single_cat _title
-
Trying to use get_template_part with single_cat_title.
Does not give me an error but does not work. I’ve tried so many slightly tweaked versions of this but just not familiar enough with PHP yet to know why none of them work. (Works fine when I just type the slug name instead of trying to get the current cat.)
Inserted single_cat_title, took out the php tags since it’s already within tags (examples I saw used periods?) and added the false statement to parse the cat title, not print it.
<?php get_template_part(‘. single_cat_title(“”,FALSE).’)?>
Did I totally mangle this??
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘PHP within PHP – How to use get_template_part with single_cat _title’ is closed to new replies.