• Resolved benneja1

    (@benneja1)


    Looking to use easy modal to pop a notification box when a user selects a check box in a form. As it stands now, when they click the check box it pops the modal message but when they close the message the check box remains unchecked.

    Check box setup:
    <nobr><input class=”eModal-1″ type=”checkbox” name=”type[]” value=”testing” />testing</nobr>

    The site is on a network without internet access so I am unable to provide a link.

    https://www.ads-software.com/plugins/easy-modal/

Viewing 1 replies (of 1 total)
  • Plugin Author Daniel Iser

    (@danieliser)

    Ok so the function that runs when you click a modal link uses e.preventDefault() which as you may have figured out stops the click from doing its default action, such as changing pages etc.

    So the default function of the checkbox isn’t fired, so it remains unchecked.

    You can make your own open function and add it to your themes JS or footer to get the desired affect.

    Something like

    jQuery('.eModal-1').click(function(e){
        jQuery('#eModal-1').emodal('open');
    });

    Change the ID of course but that should do it.

    Hope this helps.

Viewing 1 replies (of 1 total)
  • The topic ‘Easy Modal and Checkboxes’ is closed to new replies.