Support » Plugin: Age Gate » EventListener – agegateshown

  • Hello,

    how can I use this event listener – agegateshown please? Because I need to insert this age-gate-additional-information after this age-gate-subheading class and before age-gate-submit-yes. Can you help me please?

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author Phil

    (@philsbury)

    Hi @cleemas,

    That’s fairly straight forward. The Event is only triggered when you use the javascript mode of of age gate (in advanced settings)

    Then, you can just add the following javascript to your theme:

    
    jQuery(function () {
      jQuery(document).on('agegateshown', function () {
        jQuery('.age-gate-additional-information').insertAfter('.age-gate-subheading');
      });
    });
    

    Thanks
    Phil

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.