concat validation rules with form_validation |
Quote:I use jQuery Form validation, but that also only shows one error per field. I consider that it is important show all error that user have had when form is full, because it is boring to fill out a form several times. For example, imagine that you fill your username and now show that is very long (max_length[10]). You correct it and now show that that user exists (custom rule to avoid repeat usernames). You correct again and now show that username haven't correct format (you put a number in username that you don't permit with rule alpha). I know that it is a rare situation, but it may occur, and if application had shown all error from the beginning, user could have corrected all the errors or avoid them. I have too a form multipart with option to upload a image file. That image file must be .png or .jpg, with max. resolution 400x400 and other limitations that I set with Upload class. However, when I have an error in a field and in the image file, it shows field errors only, not for image file. Then, if I correct all error for fields, when I submit form again, now it shows errors for image file. I suppose that for this situation, it's similar that Form_validation, it shows errors one at time. Although I have: PHP Code: if( $this->form_validation->run() && $this->upload->do_upload('filename') ) When there are errors in fields and in the image file, it shows errors for fields only. |
Messages In This Thread |
concat validation rules with form_validation - by annx10 - 05-04-2017, 01:42 PM
RE: concat validation rules with form_validation - by Martin7483 - 05-04-2017, 02:05 PM
RE: concat validation rules with form_validation - by marksman - 05-04-2017, 02:38 PM
RE: concat validation rules with form_validation - by annx10 - 05-05-2017, 02:04 AM
RE: concat validation rules with form_validation - by Martin7483 - 05-05-2017, 02:14 AM
RE: concat validation rules with form_validation - by InsiteFX - 05-05-2017, 03:36 AM
RE: concat validation rules with form_validation - by annx10 - 05-06-2017, 04:23 AM
RE: concat validation rules with form_validation - by skunkbad - 05-06-2017, 08:18 AM
RE: concat validation rules with form_validation - by annx10 - 05-12-2017, 01:26 AM
|