Hello, sorry it took me a while to reply.
Currently, the [search_form]
shortcode just calls the WordPress native function get_search_form, and takes no parameters. It’s possible to filter the search by post type, but not so simple at the moment. In a future update, I’ll see if I can add a shortcode parameter to achieve the same result.
—
To display a custom search form, create a file called searchform.php in the theme or child theme. Here’s the default HTML5 form, with an additional field to limit the search by post type.
<form role="search" method="get" class="search-form" action="<?php echo home_url( '/' ); ?>">
<label>
<span class="screen-reader-text">
<?php echo _x( 'Search for:', 'label' ) ?>
</span>
<input type="search" name="s" class="search-field"
title="<?php echo esc_attr_x( 'Search for:', 'label' ) ?>"
placeholder="<?php echo esc_attr_x( 'Search …', 'placeholder' ) ?>"
value="<?php echo get_search_query() ?>"
/>
</label>
<!--- Here, the post type is specified --->
<input type="hidden" value="POST_TYPE" name="post_type" id="post_type" />
<input type="submit" class="search-submit" value="<?php echo esc_attr_x( 'Search', 'submit button' ) ?>" />
</form>
Replace POST_TYPE
with the desired custom post type’s slug. For further reference, please see the Codex here.
—
The search result page is by default displayed by search.php of the theme. You can customize it based on the page template you want.
—
So, none of this is provided by the plugin. As I mentioned above, I’ll see if I can simplify it with the shortcode.