Logo Background RSS

Add Multiple Search Boxes to your site

  • Written by Shane GoldbergShane Goldberg No Comments Comments
    Last Updated: August 4, 2008

    So you want to have a search box on your ‘Members’ only sidebar and your ‘Default’ public sidebar?

    Unfortunately WordPress does not allow this.

    However, there’s a workaround – you need to create a Text Widget with HTML like this:

    <form method=”get” action=”/”>
    <div>
    <label class=”hidden” for=”s1″>Search for:</label>
    <input type=”text” name=”s” id=”s1″ size=”15″ value=”"/>
    <input type=”submit” value=”Search”/>
    </div>
    </form>

    For every new Search widget, the index after “s” (is=”s1″, for=”s1″) should be incremented by one.

    Enjoy.

Leave a Comment

For spam filtering purposes, please copy the number 1038 to the field below: