Limit CPTs per page on homepage What would we do without the pre_get_posts filter? Another handy WP snippet to customize the...
Custom password protected text Change the output text for password protected content on your WordPress site. This snippet function...
Custom excerpt for password protected pages WordPress shows the excerpt for password protected pages. This function changes the excerpt output for...
Conditional check for all custom post types By default we can use " if ( is_singular( 'book' ) )" to check for...
Add HTML before and after admin list post table This function modifies the admin post edit screen. It adds html to the top above...
List all attachments from custom post type Sometimes you need to get all attachments (i.e. from a portfolio custom post type) and...
Enable shortcodes in text widgets This single line enables the shortcode functions in widgets. By default WordPress prints the ...
Show related posts by category There is no need for a plugin to show related posts. This snippet takes the...
Add custom post types to your feed Manage your feed content with this snippet. Set the post types your feed should include...
301 Redirect your feed to feedburner Your default feed url with permalinks is by default yoursite.com/feed/. This function replaces this with...