I have a search form on an html page that only uses two fields of the db for searching. the first field is account number and the second is company name, I can search by either field and find the record. My problem is that I need to have the search form match both fields not just one or the other. Can you offer some advice?
This is the complete code that I use in my html form:
<form action="http://www.mydomain.com/cgi-bin/db.cgi" method="GET">
<input type="hidden" name="db" value="acct"><input type="hidden" name="uid"
value="default"><center>
<table border="1" bgcolor="#FFFFFF" cellpadding="5" cellspacing="3"
width="500" align="center" valign="top">
<tr>
<td>
<p>
<center>
<font face="verdana,arial,helvetica" size="4"><b>Corporate
Account Reservations</b></font>
</center>
<table border="0">
<tr>
<td align="right" valign="top" width="20%"><font
face="verdana,arial,helvetica" size="2">Account Number:</font></td>
<td width="80%">
<input type="text" name="Account" value size="6"
maxlength="6">
</td>
</tr>
<tr>
<td align="right" valign="top" width="20%">
<p><font
face="verdana,arial,helvetica" size="2">Company </font><font
face="verdana,arial,helvetica" size="2">Name:</font></p>
</td>
<td width="80%">
<input type="text" name="AcctName" value size="30"
maxlength="30">
</td>
</tr>
</table>
<p>
<center>
<input type="SUBMIT" name="find_records" value="Submit">
<font face="Verdana, Arial, Helvetica" size="2">| </font>
</center>
</p>
</td>
</tr>
</table>
</center>
</form>
This is the complete code that I use in my html form:
<form action="http://www.mydomain.com/cgi-bin/db.cgi" method="GET">
<input type="hidden" name="db" value="acct"><input type="hidden" name="uid"
value="default"><center>
<table border="1" bgcolor="#FFFFFF" cellpadding="5" cellspacing="3"
width="500" align="center" valign="top">
<tr>
<td>
<p>
<center>
<font face="verdana,arial,helvetica" size="4"><b>Corporate
Account Reservations</b></font>
</center>
<table border="0">
<tr>
<td align="right" valign="top" width="20%"><font
face="verdana,arial,helvetica" size="2">Account Number:</font></td>
<td width="80%">
<input type="text" name="Account" value size="6"
maxlength="6">
</td>
</tr>
<tr>
<td align="right" valign="top" width="20%">
<p><font
face="verdana,arial,helvetica" size="2">Company </font><font
face="verdana,arial,helvetica" size="2">Name:</font></p>
</td>
<td width="80%">
<input type="text" name="AcctName" value size="30"
maxlength="30">
</td>
</tr>
</table>
<p>
<center>
<input type="SUBMIT" name="find_records" value="Submit">
<font face="Verdana, Arial, Helvetica" size="2">| </font>
</center>
</p>
</td>
</tr>
</table>
</center>
</form>