Perad Posted November 28, 2006 Share Posted November 28, 2006 if (empty($_POST['first_name'])) {This is ignoring zero's. Does anyone know of anything which checks to see if the submit box is empty yet perceives zero as a value. Quote Link to comment Share on other sites More sharing options...
Jenk Posted November 28, 2006 Share Posted November 28, 2006 [code=php:0]if (empty($_POST['field']) && $_POST['field'] !== 0)[/code] Quote Link to comment Share on other sites More sharing options...
Perad Posted November 28, 2006 Author Share Posted November 28, 2006 Ah of course. Its been a long day, thanks a lot :D Quote Link to comment Share on other sites More sharing options...
taith Posted November 28, 2006 Share Posted November 28, 2006 [code]if(!isset($_POST['field']))[/code] Quote Link to comment Share on other sites More sharing options...
Jenk Posted November 28, 2006 Share Posted November 28, 2006 [code=php:0]$_POST['field'] = '';[/code]That will pass your example, but not empty(). Quote Link to comment 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.