Jump to content

Archived

This topic is now archived and is closed to further replies.

goatboy

php mysql search problem

Recommended Posts

i made a search to search order numbers, if you input numbers it works correctly even if its an order number that doesn't exist it just tells you that

 

but i tested if someone where to type text, and i get a mysql error, shouldn't it do the same thing as if it were an order number that didn't exsit?

 

 

Share this post


Link to post
Share on other sites

numbers do not have to be quoted; text does. i would use some validation, such as is_numeric, before passing the data to mysql.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.