How to exclude a custom post type from WordPress search

Here is how to exclude a custom post type from the WordPress search results. Handy if using custom post types for things like a slider on home page that aren’t meant to be a stand alone posts.

Instructions
Add the following code to your WordPress functions.php file.

Related links
http://codex.wordpress.org/Function_Reference/register_post_type

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *