1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

javascript for downsells?

Discussion in 'Black Hat SEO' started by illmill, May 5, 2013.

  1. illmill

    illmill Registered Member

    Joined:
    Jun 10, 2009
    Messages:
    69
    Likes Received:
    35
    Home Page:
    Hey, what's a sample javascript code for downselling someone. For example, when someone clicks to close a page I want a message to pop up that says something like, "If you click cancel, then you can save 50%, blah blah blah" and then when they click cancel it redirects them to another page. If they click ok, then it closes the window.
     
  2. innozemec

    innozemec Jr. VIP Jr. VIP

    Joined:
    Aug 19, 2011
    Messages:
    5,290
    Likes Received:
    1,799
    Location:
    www.Indexification.com
    Home Page:
    I don't have the exact code, but you can find lots of such scripts if you google "javascript popup on exit page" or something like that..
     
  3. Furious George

    Furious George Supreme Member Premium Member

    Joined:
    Dec 13, 2012
    Messages:
    1,437
    Likes Received:
    2,176
    Trial pay has a cool feature called the "page abandonment tool"

    After a quick google search, this looks promising

    Code:
    http://wiki.xdspot.com/wiki/doku.php?id=script-exitpop
     
    • Thanks Thanks x 1
  4. illmill

    illmill Registered Member

    Joined:
    Jun 10, 2009
    Messages:
    69
    Likes Received:
    35
    Home Page:
    Thanks, I will give this a shot.
     
  5. illmill

    illmill Registered Member

    Joined:
    Jun 10, 2009
    Messages:
    69
    Likes Received:
    35
    Home Page:
    Actually, I had trouble getting this one to work and it kept crashing my html editor. BUT, I found something that's very easy and doesn't require uploading extra files.
    This needs to go between your <head> and </head> tags:
    HTML:
    <script type='text/javascript'> <!--var NoExitPage = false;function ExitPage() {    if(NoExitPage == false)    {        NoExitPage=true;        location.href='http://yourlandingpage.com/';        return"***********************************************\n\n"+               "          WAIT BEFORE YOU GO!!\n\n"+               "      Exclusive Discount Offer ($20 Value) Today Only!\n\n"+               "Click the [Cancel] Button Right Now To Stay On This Page!\n\n"+               "***********************************************";    }}// --> </script>
    And then modify your body tag to this:
    HTML:
    <body onBeforeUnload="return ExitPage();">