This forum is no longer open and is for reading/searching only.
Please use our new MachForm Community Forum instead.
MachForm Community Forums » MachForm 3
Required Field Problem
Started 12 years ago by smailek | 6 posts |
-
I think there is a problem in required field.If form has save and resume ability, then required field prevents this ability because there is a same record (at least required field) in database.
Posted 12 years ago # -
Can you explain more regarding the issue please? Do you mean you can't save the form when the form has required fields?
An URL to the form would be very helpful.You can contact us directly if you don't want to post the URL here.
MachForm Founder
Posted 12 years ago # -
I am so sorry not required field it is "no duplicate field". I have a form with a no duplicate field like SSN. Users can fill the form including SSN and then save it. But they can not resume form because there is same record in database and there is a warning about no duplicate field.
Posted 12 years ago # -
hi yuniar could u look at this problem? thank you
Posted 12 years ago # -
Sorry for that! I missed your last reply.
Anyway, I've checked and this is a bug indeed. Thank you for reporting this.Fortunately the quick is very simple. You can edit your "includes/common-validator.php" file, search around line 43 for this code:
$query = "select count($element_name) total from ".MF_TABLE_PREFIX."form_{$form_id} where {$element_name}=?";
change it to become:
$query = "select count($element_name) total from ".MF_TABLE_PREFIX."form_{$form_id} where {$element_name}=? and resume_key is null";
that should fix it.
MachForm Founder
Posted 12 years ago # -
Yeah it fixed Yuniar. Thank you
Posted 12 years ago #
Reply
You must log in to post.