Skip to content

Instantly share code, notes, and snippets.

@jchristopher
Last active January 4, 2016 02:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jchristopher/8553134 to your computer and use it in GitHub Desktop.
Save jchristopher/8553134 to your computer and use it in GitHub Desktop.
Register your Extension with SearchWP core
<?php
class SearchWPMyExtension() {
function __construct() {
add_filter( 'searchwp_extensions', array( $this, 'register' ), 10 );
}
function register( $extensions ) {
$extensions['MyExtension'] = __FILE__;
return $extensions;
}
}
new My_SearchWP_Extension();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment