In my form, I have a ID field, and if users enter that, then they need not enter any other data. So, I want my php to match propertys where, the ID matches the posted ID (which it does)
or else where the ID is a blank field and the rest of the fields (rent, postcode etc) match up.
(which it doesnt) it just finds nothing if I enter a invalid ID. Why?
"SELECT
*
FROM
propertys
WHERE
id = '$id'
OR
id = ''
AND
Postcode LIKE '%$postcode%'
AND
rent BETWEEN '$minrent' and '$maxrent'
AND
price BETWEEN '$minprice' and '$maxprice'
AND $set";