Here's the code I have
$query = "SELECT partID, fname, lname FROM tblPartInfo WHERE lname = '$lname' or fname = '$fname'";
Works like a charm.
Now, I want to be able to use wildcards so that the user can enter, for exemple, HO to search for HOUSE so I tried the following:
$query = "SELECT partID, fname, lname FROM tblPartInfo WHERE lname LIKE '$lname%' or fname LIKE '$fname%'";
It returned every record in the table so I tried :
$query = "SELECT partID, fname, lname FROM tblPartInfo WHERE lname LIKE '$lname' + '%' or fname LIKE '$fname' + '%'";
This just crashed the script.
Any input?