Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Search Specific Fields Drop Down Box

Quote Reply
Search Specific Fields Drop Down Box
Hi:

Been thinking it would be nice to add a drop down box so a user can specify what to search for in conjunction with mys really simple search box. In my case, I would like a drop down that specifies "All", "Title" and "Character" (just to keep it simple!)

So the form is:

<FORM ACTION="<%db_cgi_url%>/search.cgi" METHOD="POST">

<INPUT TYPE="text" SIZE=12 NAME="query" MAXLENGTH=75>
&nbsp;&nbsp;<INPUT TYPE="image" SRC="http://comics.bcdb.com/pages/images/buton.gif" WIDTH="15" HEIGHT="15" NAME="Search BCBdb">
<select name=select>
<option selected>All</option>
<option>Titles</option>
<option>Characters</option>
</select>
</FORM>

As you can see "query" is inputed in the Text box.... but what I am not sure about is how to change "query=XXXX" to "query=&Title=XXX" when someone chooses "Titles"

Is there a simple way to do this, or should I write a few if...then statemenst and pop themn into search.pm?

dave

Big Cartoon DataBase
Big Comic Book DataBase
Quote Reply
Re: [carfac] Search Specific Fields Drop Down Box In reply to
Nevermind- solved it! Used an intermediary script to rewrite the URL....
dave

Big Cartoon DataBase
Big Comic Book DataBase