Pop-Up Upon Leaving Website Conditional?

Is there a way to add a new conditional to the Pop-Up list which lets it come up when someone is about to leave the site (not exit the page for another internal link)?

This would be very helpful for surveys or other types of quiz questions.

Regards,

UpcomingMedia

  • UpcomingMedia

    Fair enough.

    I'm just looking for something to complement a survey/quiz plugin which doesn't have notifications.

    I find that lots of sites have a "Would you mind answering some questions when you're done." type popup which I guess stores cookie information to display window upon exit?

    Its a bit specialized but I feel the functionality could be very beneficial for a plugin like this or maybe Slide-In?

  • Vladislav

    Hello,

    The latest plugin release (v4.5, just released) comes with a couple of add-ons that might be what you're looking for. The first add-on is named "Show on exit rule" and making use of this rule will basically show your pop-up message when the user moves the mouse off the page (e.g. to close the window/tab). The other add-on is named "Show on click rule" and this rule will show your pop-up message on user clicks. The idea here is to intercept the clicks to outgoing links, so entering something like this in the selector field should hopefully do the job:

    a:not([href^="http://your-website.com"]):not([href^="#"]):not([href^="/"])

  • UpcomingMedia

    Hey @Vladislav

    This is a great update! It has the functionality I was looking for and trying to get from Slide-In. I'll test this out and see how well it performs for the survey task I have in mind.

    Keep up the great work!

    How would I utilize the code you gave me if my domain is http://upcomingmedia.com/tc/?

    Would the "Show on click rule" only work for external links? Is that the point of the selector field code?

    Cheers,

    UpcomingMedia

  • Vladislav

    Hello,

    I hope the release will have your usage scenario covered. The selector field allows the "onclick" rule to be applied to any element on your page, regardless if it's a link or not. The selector rule for the URL from your post would probably be something along the lines of:

    a:not([href^="http://upcomingmedia.com/tc/"]):not([href^="#"]):not([href^="/"])

    The rule literally means: any A element (link), which does *not* begin with "http://upcomingmedia.com/tc/" (because that's a local link), does not begin with "#" (because that's an anchor local to the page) and does not begin with "/" (because that's a relative link - relative to your site). Applying this expression on a page should then select all the external links - meaning, the links that will lead the user away from your site.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.