WordPress.org

Ready to get started?Download WordPress

Plugin Directory

!This plugin hasn't been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.

Enhanced Search Form

Enhance wordpress search form to allow searching posts in certain category(s), month archive(s) or tag(s).

  1. Upload this plugin to your WordPress plugin directory( generally wp-content/plugins/ ).
  2. Activate it in admin area.
  3. Your theme should have a hardcoded search form or you should add a "Search" widget to sidebar to allow visitors searching.
  4. Check whether or not there is a "searchform.php" file in your current theme directory, if not, you don't need do anything; If yes, edit this "searchform.php" following the below instructions:

Your theme's "searchform.php" file may looks like below, with some other codes:

....
<form method="get" id="searchform" action="<?php bloginfo('url'); ?>">
    <input type="text" id="s" name="s" value="<?php the_search_query(); ?>"  />
    <input type="submit" id="searchsubmit" value="Search" />
</form>
...

add the <?php if(function_exists('esf_add_form_field')) esf_add_form_field(); ?> code to proper place inside <form> element, in most cases you can put it just after <input type="submit" value="Search" /> button and before </form> close tag.

That's all. You may want to add css styles to make search form nicer.

Requires: 2.7 or higher
Compatible up to: 2.8.4
Last Updated: 2009-9-18
Downloads: 7,980

Ratings

5 stars
5 out of 5 stars

Support

Got something to say? Need help?

Compatibility

+
=
Not enough data

0 people say it works.
0 people say it's broken.

50,4,2
0,1,0
100,1,1
0,1,0