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

Comparing two fields for validation


  1. johnlaidlaw
    Member

    I have adapted some code from another thread to compare two hidden fields.

    if($form_id == 2456){ if($input['element_70'] == $input['element_73']){ $process_result['status'] = true; $process_result
    ['custom_error'] = 'Please use the link provided on your original confirmation email from us to open the Publicity Form for a
    performance. Call us if you need this resent.'; } }

    This is in includes/post-functions just above:

    $element_child_lookup['address'] = 5;
    $element_child_lookup['simple_name'] = 1;

    The form has two pages and this evaluates fine when using the Continue at the end of the first page. However it does not evaluate correctly when Submitting at the end of the form. i.e.it revreses the validation. Do I need to put this if clause somwhere else as well?

    Posted 11 years ago #

RSS feed for this topic

Reply