Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

106
Views
Exit Intent in Mobile using javascrpt or jQuery

I tried modifying the plugin to show a modal popup when a website visitor leaves the page using haschange, but it still doesn't work. How to get it to work? I need help fixing it

 $(document).ready(function(e) {

    var exit_intent_popup_hash = 'b'
    window.location.hash = exit_intent_popup_hash
    window.history.back()

    setTimeout(function() {
        window.history.forward()
        $('.fel-modal-parent-wrapper').each(function() {

            var $this = $(this);
            var tmp_id = $this.attr('id');
            var popup_id = tmp_id.replace('-overlay', '');
            var trigger_on = $this.data('trigger-on');
            var exit_intent = $this.data('exit-intent');

            if ('automatic' == trigger_on) {
                if ('yes' == exit_intent && FelModalPopup_canShow(popup_id)) {
                
                    $(window).hashchange(function() {
                        if (window.location.hash !== `#${exit_intent_popup_hash}`) {
                            FelModalPopup_show(popup_id);
                            window.history.forward()
                        }
                    }, false);
                }
            }
        });
    }, 500);
});
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!