Placement of categories

While you may not be able to integrate your categories list directly into the slider (this is dependent on how the slider is set up and I haven’t used this particular theme), it’s possible to display a list of categories and their links that functions in the way you’ve asked and then apply the same … Read more

get_category_parents displays an empty category

How do I remove the last, empty category without PHP functions like explode or substr? You don’t. Look at the source: http://core.trac.wordpress.org/browser/tags/3.6.1/wp-includes/category-template.php#L42 The output you see is intended behavior and there is no filter. My guess is that you are trying to use the function for something it is not meant for. You could take … Read more

Pluck single parent category from get_the_category

You can check the category ‘parent’ arribute, and if is 0 the category is a parent one. I’ve also noted some things on your code: When the is is passed get_the_category is unused, but it is called anyway You use get_the_category assuming function are called in the loop, but there is no check for that … Read more

Create Cross Promoting Categories in WordPress Using ‘pre_get_posts’

I think I remember seeing this attempt somewhere… If I remember correctly, the solution was to use a custom tax query on the category.php template, but querying the taxonomy (crosspostcategory) FIRST in the “or” statement… So you’d check for the taxonomy first, and then query (tax query) the category taxonomy next in the OR statement. … Read more