Update/change category of a post when it’s been inactive for a certain number of days

https://codex.wordpress.org/Function_Reference/wp_schedule_event You can try using scheduled job to solve this. In the hook, you would write a function that checks all posts from yesterday and see which posts have received no comments. Then you will move those posts to cat 2 from cat 1. I would come up with mock code if you can give … Read more

Can’t filter categories using isotope

Try to prevent the default behaviour of the click event using jQuery right from the beginning: jQuery(function ($) { var $container = $(‘#isotope-list’); //The ID for the list with all the blog posts var $isotope = $container.isotope({ //Isotope options, ‘item’ matches the class in the PHP itemSelector : ‘.item’, layoutMode : ‘masonry’ }); //Add the … Read more

Get categories by title descendant

If only you could use get_categories() reference in the Codex, you could see that this function supports arguments. <?php $categories = get_categories( array( ‘orderby’ => ‘name’, // default value, can omit it ‘order’ => ‘DESC’ )); foreach($categories as $cat) { // your code goes here }

Remove “All categories” from searchbar dropdown

This list can be modified using WooCommerce filters. However, without a thorough testing I could not find a specific filter to help you. You might check the API for a better answer. Meanwhile, I have used this CSS snippet to successfully hide the “All Categories” entry from the drop-down selector: li.option[data-value=””] { display: none; } … Read more

Categories are not showing up according to the hierarchy

the categories can be order differently, it will depend of the arguments in the get_categories() function, once none is specified, it will assume the default. try this to have an idea: $cats = get_categories(); echo ‘<pre>’; print_r($cats); echo </pre>’; exit(); This will give you everything store in $cats variable. For example normally I use the … Read more