thanks for the reply big.nerd.
About the year input...It's just a text field like the other inputs:
Here's the form in my html page:
<FORM action="query.php" method="post">
<P align="right">
fieldone: <INPUT type="text" name="titleofcomic"><BR>
fieldtwo: <INPUT type="text" name="publisher"><BR>
fieldthree: <INPUT type="text" name="genre"><BR>
fieldfour: <INPUT type="text" name="author"><BR>
fieldfive: <INPUT type="text" name="artist"><BR>
Year: <INPUT type="text" maxlength=4 size=5 name="yearpublished">
</P>
<P align="right">
<INPUT class="button" type="submit" value="Search">
<INPUT class="button" type="reset" value="Reset">
</P>
</FORM>
The 'searcher' simply types the year in, however the max length is restricted to 4.
The first five fields are like:
fname
surname
team
etc...
All the fields, including the 'year' field are text fields, the only difference is the user is expected to type text in the first five fields such as names, whereas in the 'year' field the user is prompted to type a 4 digit number (the year).
Hope that makes more sense.
My problem isn't related to the 'year' part specifically. My problem is I can't get the query to ignore all the empty fields (i.e. "") but use the fields that have been set together.
I've tried so much but I just can't seem to fix it.