if($username=="") { $login_domain_error="Enter User Name"; }
if(isset($_POST['passwd'])) {
$login_p_error="Enter Pa开发者_如何学JAVAssword";
When I enter the above two validation, it triggers the validation errors, without form submission using PHP
What exactly is wrong
Thanks Jean
Well, you're checking if $_POST['passwd']
is set, and if that's the case, you define an error.
What's your error message?
Anyway, you should change if(isset($_POST['passwd'])) {
to if(empty($_POST['passwd'])) {
and add a }
to that.
精彩评论