email validation
Permalink
Built form with certain items required and catcha, easy. Cannot get email input to validate. Type one character and it's sent, no error on missing '@'or '.' . Found the string that I thought would throw the error, but it does not implement. do I need to do something else to get it to work?
Tried the form patches they don't seem to work either.
So is it me or something else?
Please help, spent most the weekend trying to get this to work........
Tried the form patches they don't seem to work either.
So is it me or something else?
Please help, spent most the weekend trying to get this to work........
I have now produced my own through 'Flash and PHP'
Sorry kino, did not work for me. Ajax = errors
Thank you anyway.
Sorry kino, did not work for me. Ajax = errors
Thank you anyway.
Try this...
Create the a controller.php in /BLOCKS/FORM/ and copy the controller.php from /CONCRETE/BLOCKS/FORM/ to that.
About line 218, replace:
with
I've had success with this on my AJAX form.
Create the a controller.php in /BLOCKS/FORM/ and copy the controller.php from /CONCRETE/BLOCKS/FORM/ to that.
About line 218, replace:
//checked required fields foreach($rows as $row){ if( intval($row['required'])==1 ){ $notCompleted=0; if($row['inputType']=='checkboxlist'){ $answerFound=0; foreach($_POST as $key=>$val){ if( strstr($key,'Question'.$row['msqID'].'_') && strlen($val) ){ $answerFound=1; } } if(!$answerFound) $notCompleted=1; }elseif($row['inputType']=='fileupload'){ if( !isset($_FILES['Question'.$row['msqID']]) || !is_uploaded_file($_FILES['Question'.$row['msqID']]['tmp_name']) ) $notCompleted=1;
Viewing 15 lines of 21 lines. View entire code block.
with
//checked required fields $email_error=0; $errors['CompleteRequired'] = "<br>"; foreach($rows as $row){ if( intval($row['required'])==1 ){ $notCompleted=0; if($row['inputType']=='checkboxlist'){ $answerFound=0; foreach($_POST as $key=>$val){ if( strstr($key,'Question'.$row['msqID'].'_') && strlen($val) ){ $answerFound=1; } } if(!$answerFound) $notCompleted=1; }elseif($row['inputType']=='fileupload'){
Viewing 15 lines of 42 lines. View entire code block.
I've had success with this on my AJAX form.
http://www.concrete5.org/index.php?cID=25525...
and if you need email validation, then for now a custom coded form using a single page is your best bet.