Display all the terms within a custom taxonomy

get_terms() creates a WP_Term_Query() and then passed the $args to it. It also applies the get_terms filter to the terms before they’re returned. get_terms() is, in this case, a convenience function, to use if you don’t need all the bells and whistles a WP_Term_Query might provide. As far as the_title() and the_permalink(), those functions are … Read more

Check the stored / cached WP_Query with transients on post change

Use the save_post hook to check if a post that is being saved is a portfolio page and reset the transient. add_action( ‘save_post’, ‘reset_portfolio_transient’, 10,3 ); function reset_portfolio_transient( $post_id, $post, $update ) { // Only set for portfolio post_type if ( ‘portfolio’ !== get_post_type($post) ) { return; } // delete old tranisent delete_transient( ‘randomizeProfiles’ ); … Read more

WordPress posts loop not displaying all posts on blog

if anyone else is having the same problem as me, here is the solution. The problem that was causing this was <?php echo get_permalink(the_post()); ?> Honestly, I have no idea why I went with this instead of just the_permalink() , was having a problem with my read more button it was sending me to a … Read more