Actually, you don't even want sortby, do you? Didn't we discuss that earlier?
I think the easiest way to do this would be
# --------------------------------------------------------
# Search options to be displayed at the bottom of search forms.
#
unless ($db_userid eq "default") {
print qq~
<P>
<STRONG>Search Options:</STRONG> <br>
<INPUT TYPE="CHECKBOX" NAME="cs"> Match Case
<INPUT TYPE="CHECKBOX" NAME="ww"> Whole Words
<INPUT TYPE="CHECKBOX" NAME="re"> Reg. Expression<BR>
<INPUT TYPE="TEXT" NAME="keyword" SIZE=15 MAXLENGTH=255> Keyword Search <FONT SIZE=-1> (will match against all fields)</FONT><BR>
<INPUT TYPE="TEXT" NAME="mh" VALUE="$db_max_hits" SIZE=3 MAXLENGTH=3> Max. Returned Hits<BR>
Sort By:
<SELECT NAME="sb">
<OPTION>---
~; for (my $i =0; $i <= $#db_cols; $i++) { print qq~<OPTION VALUE="$i">$db_cols[$i]</OPTION>\n~ if ($db_form_len{$db_cols[$i]} >= 0); } print qq~
</SELECT>
Sort Order:
<SELECT NAME="so">
<OPTION VALUE="ascend">Ascending
<OPTION VALUE="descend">Descending
</SELECT><br><br>
<strong>Search Tips:</strong><br>
- use '*' to match everything in a field)<BR>
- put a '>' or '<' at the beginning to to do range searches.<BR>
~;
}
else {
print qq~
<INPUT TYPE="TEXT" NAME="keyword" SIZE=15 MAXLENGTH=255> Keyword Search <FONT SIZE=-1> (will match against all fields)</FONT>
<input type="hidden" name="sb" value="the number of your Store Name field">
~;
}
}
I also took out the "Match Any" option, since you have that as a hidden field in html_view_search.
------------------
JPD
[This message has been edited by JPDeni (edited August 31, 1999).]
I think the easiest way to do this would be
Code:
sub html_search_options { # --------------------------------------------------------
# Search options to be displayed at the bottom of search forms.
#
unless ($db_userid eq "default") {
print qq~
<P>
<STRONG>Search Options:</STRONG> <br>
<INPUT TYPE="CHECKBOX" NAME="cs"> Match Case
<INPUT TYPE="CHECKBOX" NAME="ww"> Whole Words
<INPUT TYPE="CHECKBOX" NAME="re"> Reg. Expression<BR>
<INPUT TYPE="TEXT" NAME="keyword" SIZE=15 MAXLENGTH=255> Keyword Search <FONT SIZE=-1> (will match against all fields)</FONT><BR>
<INPUT TYPE="TEXT" NAME="mh" VALUE="$db_max_hits" SIZE=3 MAXLENGTH=3> Max. Returned Hits<BR>
Sort By:
<SELECT NAME="sb">
<OPTION>---
~; for (my $i =0; $i <= $#db_cols; $i++) { print qq~<OPTION VALUE="$i">$db_cols[$i]</OPTION>\n~ if ($db_form_len{$db_cols[$i]} >= 0); } print qq~
</SELECT>
Sort Order:
<SELECT NAME="so">
<OPTION VALUE="ascend">Ascending
<OPTION VALUE="descend">Descending
</SELECT><br><br>
<strong>Search Tips:</strong><br>
- use '*' to match everything in a field)<BR>
- put a '>' or '<' at the beginning to to do range searches.<BR>
~;
}
else {
print qq~
<INPUT TYPE="TEXT" NAME="keyword" SIZE=15 MAXLENGTH=255> Keyword Search <FONT SIZE=-1> (will match against all fields)</FONT>
<input type="hidden" name="sb" value="the number of your Store Name field">
~;
}
}
I also took out the "Match Any" option, since you have that as a hidden field in html_view_search.
------------------
JPD
[This message has been edited by JPDeni (edited August 31, 1999).]