Originally posted by matt_4013
Use wildcards (%) in your query, eg.
$search_string = "wand";
$sql = "SELECT * FROM inv WHERE class='%".$search_string."%'";
By putting the % in front and back it will match anything with the word wand in it 🙂 [/B]
I think that I am getting it. I am using the following:
$sql = "SELECT * FROM inv WHERE class='%".$srch."%' or item='%".$srch."%' or dis='%".$srch."%' ORDER BY inv desc";
If I " echo $srch; ", then it displays what it is searching for but when I get this, I am not getting the data that I am searching for, even though I can see it in the raw data.
Thanks in advance for any assistance on this.
John