Created
January 5, 2016 06:07
-
-
Save EnragedSuccubus/bfafab71757737700e46 to your computer and use it in GitHub Desktop.
Adding Custom Post Types to Omnisearch in Jetpack
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Add our $post_type_name to Omnisearch! | |
if ( class_exists( 'Jetpack_Omnisearch_Posts' ) ) { | |
class CG_Post_Type_Omnisearch extends Jetpack_Omnisearch_Posts { | |
var $post_type = 'post-type-id-here'; | |
} | |
new CG_Post_Type_Omnisearch; | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment