co.ador Posted January 7, 2010 Share Posted January 7, 2010 I have a form that has 5 fields, One is name, zip, state and two string arrays. When validating the name input field what other checking beside isEmpty and isNull has to be done in the input field name in order to fully validate the field? Quote Link to comment https://forums.phpfreaks.com/topic/187532-search-engine-form-validation/ Share on other sites More sharing options...
Catfish Posted January 7, 2010 Share Posted January 7, 2010 if you're going to use the string in a SQL query make sure you use mysql_real_escape_string(). http://au.php.net/manual/en/function.mysql-real-escape-string.php Quote Link to comment https://forums.phpfreaks.com/topic/187532-search-engine-form-validation/#findComment-990145 Share on other sites More sharing options...
oni-kun Posted January 7, 2010 Share Posted January 7, 2010 What you should really use is isset, instead of isNull. And what is isEmpty, Do you mean empty? mysql_real_escape_string is a good idea for queries to check for injection. But you've not told us much more, so it's hard to suggest much. Quote Link to comment https://forums.phpfreaks.com/topic/187532-search-engine-form-validation/#findComment-990150 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.