How can I block someone from accessing custom thank you URL directly?

  • mveeken4
    Asked on November 22, 2020 at 4:30 AM

    Hello. I am still in the testing stages of my JotForm. I LOVE it so far. However, on submissions I would like to redirect to my own Thank You page on my website. However, on my own website I would like to restrict direct url access to my access page. When I code my Thank You page for this restriction, it also blocks traffic from JotForm, so the Thank you page is not displayed.

    The code I found which should allow JotForm is this:

    [code]
    $referer = $_SERVER['HTTP_REFERER'];
    $referer_parse = parse_url($referer);

    if($referer_parse['host'] == "form.jotform.com" || $referer_parse['host'] == "https://form.jotform.com") {

       // Page content will display
    } else {

         header("Location: http://www.mywebsite.com/page");

      exit();

    }
    [code]

    However, page content does NOT display and there is no redirect. Is there another workaround? Basically I don't want direct url access to my Thank You page but I DO WANT JotForm to be able to access it. Thank in advance for your help.

    Jotform Thread 2718363 Screenshot
  • Welvin Support Team Lead
    Replied on November 22, 2020 at 10:09 AM

    I cannot get this to work either. I'll recheck this and let you know once I came up with the solution.

    Thank you.

  • mveeken4
    Replied on November 24, 2020 at 6:47 PM

    THANK YOU. Not a big deal, but would be nice to set it up that way. If you come up with anything, please let me know. I've been trying a few different coding variations but still nothing working as intended.



  • Jed_C
    Replied on November 24, 2020 at 9:31 PM

    We'll let you know here once we have a solution to this. Thank you for your patience in the meantime.

  • Welvin Support Team Lead
    Replied on November 26, 2020 at 10:25 AM

    Thank you for patiently waiting.

    The following codes work https://pastiebin.com/5fbfc747194ef. Just get the same codes at the top and bottom.

    2020 11 26 007 Screenshot 10

    And change your custom redirect.

    Here's a demo: https://form.jotform.com/203303840100031.

    If you submit the form, you'll be redirected to https://shots.jotform.com/welvin/html/thanks1.php. If you access this custom thank you URL without submitting the form, you'll be redirected here https://shots.jotform.com/welvin/html/thanks1.html.

    I hope that helps.

    Please contact us again if we can help in any way.

  • mveeken4
    Replied on December 2, 2020 at 6:21 PM

    Thank you for looking into this. It’s not quite working. The form does re-direct to my custom Thank You page, but the thank you page does not display the “Thank You” dialogue. It only displays the same page appearance as if I went to the URL directly. This is my Thank You Page that I want the form users to see after they submit the form.


    1606951131 5fc820db5e1fd Thank you page Screenshot 10


    When I put the php code on the top of the page ( if(stristr($_SERVER['HTTP_REFERER'], "jotform.com")) {    ) and then the other snippet at the bottom of the page

     (}

    else {

    header("Location: http://www.purden.com");

    } )


    Then both direct browsing to the URL of the Thank You page AND re-direct from filling out the Jotform form, the page looks like this:


    1606951232 5fc82140dc366 ThankYouPageScr Screenshot 21


    It is a blank page, even when redirected from JotForm. I hope this makes sense. I’ll keep working on it, but thanks for any help you can provide.


    Regards

    Michaela

  • Jed_C
    Replied on December 2, 2020 at 7:33 PM

    The extension in your screenshot shows .php.html which is invalid and won't parse the .php code.

    1606955474 5fc831d2b4e5b How can I block Screenshot 10

    Also, this page page http://www.purden.com/rentalsreservationthankyou.php doesn't contain any thank you message.

    1606955599 5fc8324fe0790 www Screenshot 21

    You might need to update that page. You can provide us the entire script you are working on so we can review the source code.

    Looking forward for your response.

  • mveeken4
    Replied on December 3, 2020 at 2:14 AM

    Thank you again for your help. Firstly the url ending in .php.html only shows up in the preview from my editor. That page that you mentioned that doesn't have a Thank You message because the code was coded for no direct access.The Thank You Page should look like this:

    1606977451 5fc887ab69db1 Thank you page Screenshot 10

    -------------------------------------------------------------------------------------------------

    Here is the code for the Thank You Page that I want the Jotform redirected to (no php snippet for restricted access).

    <!DOCTYPE html>
    <html>
    <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="generator" content="RocketCake">
    <title></title>
    <link rel="stylesheet" type="text/css" href="rentalsreservationthankyoucopy_php.css">
    </head>
    <body>
    <div class="textstyle1">
    <div id="container_10123b37"><div class="textstyle1"><div id="container_11ffcbb9"><div id="container_11ffcbb9_padding" ><div class="textstyle2"><div id="html_7a017de"><a target="_blank" title="follow me on instagram" href="https://www.instagram.com/skipurden"><img alt="follow me on instagram" src="https://c866088.ssl.cf3.rackcdn.com/assets/instagram40x40.png" border=0></a></div>
    <div id="html_135af950"><a target="_blank" title="follow me on facebook" href="https://www.facebook.com/PurdenSkiVillage"><img alt="follow me on facebook" src="https://c866088.ssl.cf3.rackcdn.com/assets/facebook40x40.png" border=0></a></div>
    <div id="container_18ac6101"><div id="container_18ac6101_padding" ></div></div><span class="textstyle3">    </span></div>
    <div style="clear:both"></div></div></div><div id="container_5fe35c8c"><div id="container_5fe35c8c_padding" ><div class="textstyle2"><div id="slide_38466eeb">
    <script type="text/javascript" src="rc_images/wsp_slideshow.js"></script>
    <script type="text/javascript">
    var js_slide_38466eeb= new wsp_slideshow('slide_38466eeb',['rc_images/20160221_122020_hdr_1024x576.jpg', 'rc_images/20160314_122419_1024x576.jpg', 'rc_images/20180208_150429_cropped_for_rocketcake_1024x354.jpg', 'rc_images/purden_topbaker_f850x260.jpg'], 'fade', 2000, 250, 'cover', null);
    </script>
    </div><div id="text_1bdabace"><div class="textstyle2"><div id="html_be6d537"><a href="https://www.wunderground.com/dashboard/pws/IREGIO15"><img src="http://banners.wunderground.com/cgi-bin/banner/ban/wxBanner?bannertype=wxstnsticker_metric&weatherstationcount=IREGIO15" height="100" width="150" border="0" alt="Weather Underground PWS IREGIO15" /></a></div>
    </div>
    </div><div id="text_4fa989fb"><div class="textstyle2">  <span class="textstyle4">Purden Ski Hill Lodge</span>
    </div>
    </div></div>
    <div style="clear:both"></div></div></div><div id="container_47b522d4"><div id="container_47b522d4_padding" ><div class="textstyle2"><div id="menu_247aa6bc"><div  class="menuholder1"><a href="javascriptDISABLED:void(0);">
    <div id="menuentry_77fb021c"  class="style1 menu_247aa6bc_mainMenuEntry mobileEntry">
    <div class="style2">
      <span class="textstyle5">Menu &#8801;</span>
    </div>
    </div>
    </a>
    <a href="skihome.html" style="text-decoration:none">
    <div id="menuentry_70e7caee"  class="style3 menu_247aa6bc_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Home</span>
    </div>
    </div>
    </a>
    <a href="skiabout.html" style="text-decoration:none">
    <div id="menuentry_9736c77"  class="style4 menu_247aa6bc_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">About</span>
    </div>
    </div>
    </a>
    <a href="snowreport.html" style="text-decoration:none">
    <div id="menuentry_61be078d"  class="style5 menu_247aa6bc_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Snow Report</span>
    </div>
    </div>
    </a>
    <a href="skihours.html" style="text-decoration:none">
    <div id="menuentry_3f716a0"  class="style6 menu_247aa6bc_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Hours</span>
    </div>
    </div>
    </a>
    <a href="javascriptDISABLED:void(0);">
    <div id="menuentry_428d126c"  class="style7 menu_247aa6bc_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Rates</span>
    </div>
    </div>
    </a>
    <a href="javascriptDISABLED:void(0);">
    <div id="menuentry_ef77fd4"  class="style8 menu_247aa6bc_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Rentals &amp; Lessons</span>
    </div>
    </div>
    </a>
    <a href="javascriptDISABLED:void(0);">
    <div id="menuentry_708bf80a"  class="style9 menu_247aa6bc_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Groups</span>
    </div>
    </div>
    </a>
    <a href="skicabins.html" style="text-decoration:none">
    <div id="menuentry_4eaf8885"  class="style10 menu_247aa6bc_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Stay</span>
    </div>
    </div>
    </a>
    <a href="skicontact.html" style="text-decoration:none">
    <div id="menuentry_33d4d544"  class="style11 menu_247aa6bc_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Contact</span>
    </div>
    </div>
    </a>


    <script type="text/javascript" src="rc_images/wsp_menu.js"></script>
    <script type="text/javascript">
    var js_menu_247aa6bc= new wsp_menu('menu_247aa6bc', 'menu_247aa6bc', 10);


    js_menu_247aa6bc.createMenuForItem('menuentry_77fb021c', ["  <span class=\"textstyle7\">Home</span> ", '', '',
                                       "  <span class=\"textstyle7\">About</span> ", 'skiabout.html', '',
                                       "  <span class=\"textstyle7\">Snow Report</span> ", 'snowreport.html', '',
                                       "  <span class=\"textstyle7\">Hours</span> ", 'skihours.html', '',
                                       "<div style=\"white-space:nowrap; overflow:hidden;\"><span style=\"display:inline-block; float:left;\">  <span class=\"textstyle7\">Rates</span> </span><span style=\"display:inline-block; float:right; padding-top:1px; font-size:7pt; font-family:Arial, Helvetica, sans-serif; color:#000000; \"/>&#x25BA;</span></div>", ["  <span class=\"textstyle7\">Day Tickets</span> ", 'skitickets.html', '',
                                       "  <span class=\"textstyle7\">Punch Cards</span> ", 'skitickets.html#Punch Cards', '',
                                       "  <span class=\"textstyle7\">Seasons Passes</span> ", 'skitickets.html#Seasons Passes', '',
                                       "  <span class=\"textstyle7\">Corporate Passes</span> ", 'skitickets.html#Corporate Passes', '',
                                       "  <span class=\"textstyle7\">Gift Certificates</span> ", 'skitickets.html#Gift Certificates', ''], '',
                                       "<div style=\"white-space:nowrap; overflow:hidden;\"><span style=\"display:inline-block; float:left;\">  <span class=\"textstyle7\">Rentals &amp; Lessons</span> </span><span style=\"display:inline-block; float:right; padding-top:1px; font-size:7pt; font-family:Arial, Helvetica, sans-serif; color:#000000; \"/>&#x25BA;</span></div>", ["  <span class=\"textstyle7\">Rental Rates</span> ", 'skirentals_lessons.php', '',
                                       "  <span class=\"textstyle7\">Lesson Rates</span> ", 'skirentals_lessons.php#Lesson Rates', ''], '',
                                       "<div style=\"white-space:nowrap; overflow:hidden;\"><span style=\"display:inline-block; float:left;\">  <span class=\"textstyle7\">Groups</span> </span><span style=\"display:inline-block; float:right; padding-top:1px; font-size:7pt; font-family:Arial, Helvetica, sans-serif; color:#000000; \"/>&#x25BA;</span></div>", ["  <span class=\"textstyle8\">School/Weekday Group Rates</span> ", 'skigroup.html', '',
                                       "  <span class=\"textstyle8\">Weekend Group Rates</span> ", 'skigroup.html#Weekend Group Rates', '',
                                       "  <span class=\"textstyle8\">Group Forms</span> ", 'skigroup.html#Group Forms', ''], '',
                                       "  <span class=\"textstyle7\">Stay</span> ", 'skicabins.html', '',
                                       "  <span class=\"textstyle7\">Contact</span> ", 'skicontact.html', '']);
    js_menu_247aa6bc.createMenuForItem('menuentry_70e7caee', []);
    js_menu_247aa6bc.createMenuForItem('menuentry_9736c77', []);
    js_menu_247aa6bc.createMenuForItem('menuentry_61be078d', []);
    js_menu_247aa6bc.createMenuForItem('menuentry_3f716a0', []);
    js_menu_247aa6bc.createMenuForItem('menuentry_428d126c', ["  <span class=\"textstyle5\">Day Tickets</span> ", 'skitickets.html', '',
                                       "  <span class=\"textstyle5\">Punch Card</span> ", 'skitickets.html#Punch Cards', '',
                                       "  <span class=\"textstyle5\">Seasons Passes</span> ", 'skitickets.html#Seasons Passes', '',
                                       "  <span class=\"textstyle5\">Corporate Passes</span> ", 'skitickets.html#Corporate Passes', '',
                                       "  <span class=\"textstyle5\">Gift Certificates</span> ", 'skitickets.html#Gift Certificates', '']);
    js_menu_247aa6bc.createMenuForItem('menuentry_ef77fd4', ["  <span class=\"textstyle5\">Rental Rates</span> ", 'skirentals_lessons.php', '',
                                       "  <span class=\"textstyle5\">Lesson Rates</span> ", 'skirentals_lessons.php#Lesson Rates', '']);
    js_menu_247aa6bc.createMenuForItem('menuentry_708bf80a', ["  <span class=\"textstyle7\">School/Weekday Group Rates</span> ", 'skigroup.html', '',
                                       "  <span class=\"textstyle7\">Weekend Group Rates</span> ", 'skigroup.html#Weekend Group Rates', '',
                                       "  <span class=\"textstyle7\">Group Forms</span> ", 'skigroup.html#Group Forms', '']);
    js_menu_247aa6bc.createMenuForItem('menuentry_4eaf8885', []);
    js_menu_247aa6bc.createMenuForItem('menuentry_33d4d544', []);


    </script>
    </div></div><span class="textstyle3"><br/></span><div id="container_4a7cc0e5"><div id="container_4a7cc0e5_padding" ><div class="textstyle2"><div id="html_25e33060"><div class="snow" />
    <style>
    .editor-stage .snow {
      height:50px;
      background: #fff;
    }
    .snow{
      position:fixed;
      pointer-events:none;
      top:0;
      left:0;
      right:0;
      bottom:0;
      height:100vh;
      background: none;
      background-image: url('https://s3-eu-west-1.amazonaws.com/static-ressources/s1.png'), url('https://s3-eu-west-1.amazonaws.com/static-ressources/s2.png'), url('https://s3-eu-west-1.amazonaws.com/static-ressources/s3.png');
      z-index:100;
      -webkit-animation: snow 10s linear infinite;
      -moz-animation: snow 10s linear infinite;
      -ms-animation: snow 10s linear infinite;
      animation: snow 10s linear infinite;
    }
    @keyframes snow {
      0% {background-position: 0px 0px, 0px 0px, 0px 0px;}
      50% {background-position: 500px 500px, 100px 200px, -100px 150px;}
      100% {background-position: 500px 1000px, 200px 400px, -100px 300px;}
    }
    @-moz-keyframes snow {
      0% {background-position: 0px 0px, 0px 0px, 0px 0px;}
      50% {background-position: 500px 500px, 100px 200px, -100px 150px;}
      100% {background-position: 400px 1000px, 200px 400px, 100px 300px;}
    }
    @-webkit-keyframes snow {
      0% {background-position: 0px 0px, 0px 0px, 0px 0px;}
      50% {background-position: 500px 500px, 100px 200px, -100px 150px;}
      100% {background-position: 500px 1000px, 200px 400px, -100px 300px;}
    }
    @-ms-keyframes snow {
      0% {background-position: 0px 0px, 0px 0px, 0px 0px;}
      50% {background-position: 500px 500px, 100px 200px, -100px 150px;}
      100% {background-position: 500px 1000px, 200px 400px, -100px 300px;}
    }
    </style>
    <p></div>
    </div>
    <div class="textstyle1"><img src="rc_images/free_digital_scrapbook_sweet_word.png" id="img_fb3be96" alt="" title="" />
    <span class="textstyle9"><br/></span><span class="textstyle3">THANK YOU!  Your Rentals Reservation submission has been received. <br/>We'll have your equipment set up and ready for you to pick up when you arrive.<br/><br/></span><span class="textstyle10">Want to purchase your tickets too?</span><span class="textstyle3"><br/>(Tickets will be ready with your rental gear)</span></div>
    <div class="textstyle2"><span class="textstyle3"><br/></span></div>
    <div class="textstyle1"><div id="html_795ceeff">
        <a
          href="javascriptDISABLED:void(
            window.open(
              'https://form.jotform.com/203123998419260',
              'blank',
              'scrollbars=yes,
              toolbar=no,
              width=700,
              height=500'
            )
          )
        "
    ><span style="color:white;">
    CLICK HERE<BR>to Purchase your Lift Tickets Online
        </span></a></div>
    <span class="textstyle11"><br/></span><span class="textstyle11"><br/></span><img src="rc_images/boarder_giphy.gif" id="img_6cfc864b" alt="" title="" />
    <img src="rc_images/skier_giphy.gif" id="img_3c15ed1b" alt="" title="" />
    <span class="textstyle11"><br/></span><span class="textstyle12"> </span></div>
    <div class="textstyle2"></div>
    <div style="clear:both"></div></div></div></div>
    <div style="clear:both"></div></div></div></div>
    <div class="textstyle13"><div id="container_5515c9eb"><div id="container_5515c9eb_padding" ><div class="textstyle2"><span class="textstyle3"> </span><div id="menu_1269d828"><div  class="menuholder1"><a href="javascriptDISABLED:void(0);">
    <div id="menuentry_6060f315"  class="style12 menu_1269d828_mainMenuEntry mobileEntry">
    <div class="style2">
      <span class="textstyle14">Menu &#8801;</span>
    </div>
    </div>
    </a>
    <a href="skihome.html" style="text-decoration:none">
    <div id="menuentry_4d7f42c2"  class="style13 menu_1269d828_mainMenuEntry normalEntry">
    <div class="style14">
      <span class="textstyle15">Home</span>
    </div>
    </div>
    </a>
    <a href="snowreport.html" style="text-decoration:none">
    <div id="menuentry_4dd934f4"  class="style15 menu_1269d828_mainMenuEntry normalEntry">
    <div class="style14">
      <span class="textstyle15">Snow Report</span>
    </div>
    </div>
    </a>
    <a href="skihours.html" style="text-decoration:none">
    <div id="menuentry_51de0c92"  class="style16 menu_1269d828_mainMenuEntry normalEntry">
    <div class="style14">
      <span class="textstyle15">Hours</span>
    </div>
    </div>
    </a>
    <a href="skicontact.html" style="text-decoration:none">
    <div id="menuentry_f71282c"  class="style17 menu_1269d828_mainMenuEntry normalEntry">
    <div class="style14">
      <span class="textstyle15">Contact</span>
    </div>
    </div>
    </a>
    <a href="javascriptDISABLED:void(0);">
    <div id="menuentry_bb4b2f6"  class="style18 menu_1269d828_mainMenuEntry normalEntry">
    <div class="style19">
    </div>
    </div>
    </a>


    <script type="text/javascript" src="rc_images/wsp_menu.js"></script>
    <script type="text/javascript">
    var js_menu_1269d828= new wsp_menu('menu_1269d828', 'menu_1269d828', 10);


    js_menu_1269d828.createMenuForItem('menuentry_6060f315', ["  <span class=\"textstyle15\">Home</span> ", '', '',
                                       "  <span class=\"textstyle15\">Snow Report</span> ", 'snowreport.html', '',
                                       "  <span class=\"textstyle15\">Hours</span> ", 'skihours.html', '',
                                       "  <span class=\"textstyle15\">Contact</span> ", 'skicontact.html', '']);
    js_menu_1269d828.createMenuForItem('menuentry_4d7f42c2', []);
    js_menu_1269d828.createMenuForItem('menuentry_4dd934f4', []);
    js_menu_1269d828.createMenuForItem('menuentry_51de0c92', []);
    js_menu_1269d828.createMenuForItem('menuentry_f71282c', []);
    js_menu_1269d828.createMenuForItem('menuentry_bb4b2f6', []);


    </script>
    </div></div><span class="textstyle3">  </span><span class="textstyle3">                                                                            </span><div id="text_18b808f7"><div class="textstyle2">  <span class="textstyle16">&#169; 2020 Purden</span>
    </div>
    </div></div>
    <div style="clear:both"></div></div></div></div>
    </div>  </div>
    <div class="textstyle2">
    <span class="textstyle3"><br/></span>  </div>
    </body>
    </html>

    ----------------------------------------------------------------------------------------------------
    Adding the php snippets to restrict direct access and redirect: The restriction on direct access works. I am redirecting to the home page when the thank you page is accessed directly. However, the RE-DIRECT from the Jotform submission is also going to that same home page, not the Thank You Page. Here is the code of the Thank you page with the added php script as instructed.

    -------------------------------------------------------------------------------------------------------

    <?php 
    // if acces is from jotform.com, show custom page.
    if(stristr($_SERVER['HTTP_REFERER'], "jotform.com")) {
    ?><!DOCTYPE html>
    <html>
    <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="generator" content="RocketCake">
    <title></title>
    <link rel="stylesheet" type="text/css" href="rentalsreservationthankyou_php.css">
    </head>
    <body>
    <div class="textstyle1">
    <div id="container_a3b7a75"><div class="textstyle1"><div id="container_70d5e965"><div id="container_70d5e965_padding" ><div class="textstyle2"><div id="html_1277146b"><a target="_blank"
  • mveeken4
    Replied on December 3, 2020 at 2:16 AM
    <?php 
    // if acces is from jotform.com, show custom page.
    if(stristr($_SERVER['HTTP_REFERER'], "jotform.com")) {
    ?><!DOCTYPE html>
    <html>
    <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="generator" content="RocketCake">
    <title></title>
    <link rel="stylesheet" type="text/css" href="rentalsreservationthankyou_php.css">
    </head>
    <body>
    <div class="textstyle1">
    <div id="container_a3b7a75"><div class="textstyle1"><div id="container_70d5e965"><div id="container_70d5e965_padding" ><div class="textstyle2"><div id="html_1277146b"><a target="_blank" title="follow me on instagram" href="https://www.instagram.com/skipurden"><img alt="follow me on instagram0" src="https://c866088.ssl.cf3.rackcdn.com/assets/instagram40x40.png" border=0></a></div>
    <div id="html_e7e5b09"><a target="_blank" title="follow me on facebook" href="https://www.facebook.com/PurdenSkiVillage"><img alt="follow me on facebook1" src="https://c866088.ssl.cf3.rackcdn.com/assets/facebook40x40.png" border=0></a></div>
    <div id="container_4cafd39b"><div id="container_4cafd39b_padding" ></div></div><span class="textstyle3">    </span></div>
    <div style="clear:both"></div></div></div><div id="container_5e8d2adc"><div id="container_5e8d2adc_padding" ><div class="textstyle2"><div id="slide_59b31302">
    <script type="text/javascript" src="rc_images/wsp_slideshow.js"></script>
    <script type="text/javascript">
    var js_slide_59b31302= new wsp_slideshow('slide_59b31302',['rc_images/20160221_122020_hdr_1024x576.jpg', 'rc_images/20160314_122419_1024x576.jpg', 'rc_images/20180208_150429_cropped_for_rocketcake_1024x354.jpg', 'rc_images/purden_topbaker_f850x260.jpg'], 'fade', 2000, 250, 'cover', null);
    </script>
    </div><div id="text_1bbe84fa"><div class="textstyle2"><div id="html_7ca8d1c"><a href="https://www.wunderground.com/dashboard/pws/IREGIO15"><img src="//banners.wunderground.com/cgi-bin/banner/ban/wxBanner?bannertype=wxstnsticker_metric&weatherstationcount=IREGIO15" height="100" width="150" border="0" alt="Weather Underground PWS IREGIO152" /></a></div>
    </div>
    </div><div id="text_1003eba1"><div class="textstyle2">  <span class="textstyle4">Purden Ski Hill Lodge</span>
    </div>
    </div></div>
    <div style="clear:both"></div></div></div><div id="container_c7fd100"><div id="container_c7fd100_padding" ><div class="textstyle2"><div id="menu_4ce04c5d"><div  class="menuholder1"><a href="javascriptDISABLED:void(0);">
    <div id="menuentry_1fc0663d"  class="style1 menu_4ce04c5d_mainMenuEntry mobileEntry">
    <div class="style2">
      <span class="textstyle5">Menu &#8801;</span>
    </div>
    </div>
    </a>
    <a href="skihome.html" style="text-decoration:none">
    <div id="menuentry_72895ece"  class="style3 menu_4ce04c5d_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Home</span>
    </div>
    </div>
    </a>
    <a href="skiabout.html" style="text-decoration:none">
    <div id="menuentry_6aa8de12"  class="style4 menu_4ce04c5d_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">About</span>
    </div>
    </div>
    </a>
    <a href="snowreport.html" style="text-decoration:none">
    <div id="menuentry_59b67495"  class="style5 menu_4ce04c5d_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Snow Report</span>
    </div>
    </div>
    </a>
    <a href="skihours.html" style="text-decoration:none">
    <div id="menuentry_23e26a0a"  class="style6 menu_4ce04c5d_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Hours</span>
    </div>
    </div>
    </a>
    <a href="javascriptDISABLED:void(0);">
    <div id="menuentry_5773e5d8"  class="style7 menu_4ce04c5d_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Rates</span>
    </div>
    </div>
    </a>
    <a href="javascriptDISABLED:void(0);">
    <div id="menuentry_60fe9e8a"  class="style8 menu_4ce04c5d_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Rentals &amp; Lessons</span>
    </div>
    </div>
    </a>
    <a href="javascriptDISABLED:void(0);">
    <div id="menuentry_3bcf10d1"  class="style9 menu_4ce04c5d_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Groups</span>
    </div>
    </div>
    </a>
    <a href="skicabins.html" style="text-decoration:none">
    <div id="menuentry_270a18f7"  class="style10 menu_4ce04c5d_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Stay</span>
    </div>
    </div>
    </a>
    <a href="skicontact.html" style="text-decoration:none">
    <div id="menuentry_3fa3caf8"  class="style11 menu_4ce04c5d_mainMenuEntry normalEntry">
    <div class="style2">
      <span class="textstyle6">Contact</span>
    </div>
    </div>
    </a>


    <script type="text/javascript" src="rc_images/wsp_menu.js"></script>
    <script type="text/javascript">
    var js_menu_4ce04c5d= new wsp_menu('menu_4ce04c5d', 'menu_4ce04c5d', 10);


    js_menu_4ce04c5d.createMenuForItem('menuentry_1fc0663d', ["  <span class=\"textstyle7\">Home</span> ", '', '',
                                       "  <span class=\"textstyle7\">About</span> ", 'skiabout.html', '',
                                       "  <span class=\"textstyle7\">Snow Report</span> ", 'snowreport.html', '',
                                       "  <span class=\"textstyle7\">Hours</span> ", 'skihours.html', '',
                                       "<div style=\"white-space:nowrap; overflow:hidden;\"><span style=\"display:inline-block; float:left;\">  <span class=\"textstyle7\">Rates</span> </span><span style=\"display:inline-block; float:right; padding-top:1px; font-size:7pt; font-family:Arial, Helvetica, sans-serif; color:#000000; \"/>&#x25BA;</span></div>", ["  <span class=\"textstyle7\">Day Tickets</span> ", 'skitickets.html', '',
                                       "  <span class=\"textstyle7\">Punch Cards</span> ", 'skitickets.html#Punch Cards', '',
                                       "  <span class=\"textstyle7\">Seasons Passes</span> ", 'skitickets.html#Seasons Passes', '',
                                       "  <span class=\"textstyle7\">Corporate Passes</span> ", 'skitickets.html#Corporate Passes', '',
                                       "  <span class=\"textstyle7\">Gift Certificates</span> ", 'skitickets.html#Gift Certificates', ''], '',
                                       "<div style=\"white-space:nowrap; overflow:hidden;\"><span style=\"display:inline-block; float:left;\">  <span class=\"textstyle7\">Rentals &amp; Lessons</span> </span><span style=\"display:inline-block; float:right; padding-top:1px; font-size:7pt; font-family:Arial, Helvetica, sans-serif; color:#000000; \"/>&#x25BA;</span></div>", ["  <span class=\"textstyle7\">Rental Rates</span> ", 'skirentals_lessons.php', '',
                                       "  <span class=\"textstyle7\">Lesson Rates</span> ", 'skirentals_lessons.php#Lesson Rates', ''], '',
                                       "<div style=\"white-space:nowrap; overflow:hidden;\"><span style=\"display:inline-block; float:left;\">  <span class=\"textstyle7\">Groups</span> </span><span style=\"display:inline-block; float:right; padding-top:1px; font-size:7pt; font-family:Arial, Helvetica, sans-serif; color:#000000; \"/>&#x25BA;</span></div>", ["  <span class=\"textstyle8\">School/Weekday Group Rates</span> ", 'skigroup.html', '',
                                       "  <span class=\"textstyle8\">Weekend Group Rates</span> ", 'skigroup.html#Weekend Group Rates', '',
                                       "  <span class=\"textstyle8\">Group Forms</span> ", 'skigroup.html#Group Forms', ''], '',
                                       "  <span class=\"textstyle7\">Stay</span> ", 'skicabins.html', '',
                                       "  <span class=\"textstyle7\">Contact</span> ", 'skicontact.html', '']);
    js_menu_4ce04c5d.createMenuForItem('menuentry_72895ece', []);
    js_menu_4ce04c5d.createMenuForItem('menuentry_6aa8de12', []);
    js_menu_4ce04c5d.createMenuForItem('menuentry_59b67495', []);
    js_menu_4ce04c5d.createMenuForItem('menuentry_23e26a0a', []);
    js_menu_4ce04c5d.createMenuForItem('menuentry_5773e5d8', ["  <span class=\"textstyle5\">Day Tickets</span> ", 'skitickets.html', '',
                                       "  <span class=\"textstyle5\">Punch Card</span> ", 'skitickets.html#Punch Cards', '',
                                       "  <span class=\"textstyle5\">Seasons Passes</span> ", 'skitickets.html#Seasons Passes', '',
                                       "  <span class=\"textstyle5\">Corporate Passes</span> ", 'skitickets.html#Corporate Passes', '',
                                       "  <span class=\"textstyle5\">Gift Certificates</span> ", 'skitickets.html#Gift Certificates', '']);
    js_menu_4ce04c5d.createMenuForItem('menuentry_60fe9e8a', ["  <span class=\"textstyle5\">Rental Rates</span> ", 'skirentals_lessons.php', '',
                                       "  <span class=\"textstyle5\">Lesson Rates</span> ", 'skirentals_lessons.php#Lesson Rates', '']);
    js_menu_4ce04c5d.createMenuForItem('menuentry_3bcf10d1', ["  <span class=\"textstyle7\">School/Weekday Group Rates</span> ", 'skigroup.html', '',
                                       "  <span class=\"textstyle7\">Weekend Group Rates</span> ", 'skigroup.html#Weekend Group Rates', '',
                                       "  <span class=\"textstyle7\">Group Forms</span> ", 'skigroup.html#Group Forms', '']);
    js_menu_4ce04c5d.createMenuForItem('menuentry_270a18f7', []);
    js_menu_4ce04c5d.createMenuForItem('menuentry_3fa3caf8', []);


    </script>
    </div></div><span class="textstyle3"><br/></span><div id="container_582604b"><div id="container_582604b_padding" ><div class="textstyle1"><span class="textstyle9"><br/></span><div  id="placeh_1e42eb5e" >
      <div class="textstyle2">
    <span class="textstyle3"> <br/>   </span><div id="html_124caae9"><div class="snow" />
    <style>
    .editor-stage .snow {
      height:50px;
      background: #fff;
    }
    .snow{
      position:fixed;
      pointer-events:none;
      top:0;
      left:0;
      right:0;
      bottom:0;
      height:100vh;
      background: none;
      background-image: url('https://s3-eu-west-1.amazonaws.com/static-ressources/s1.png'), url('https://s3-eu-west-1.amazonaws.com/static-ressources/s2.png'), url('https://s3-eu-west-1.amazonaws.com/static-ressources/s3.png');
      z-index:100;
      -webkit-animation: snow 10s linear infinite;
      -moz-animation: snow 10s linear infinite;
      -ms-animation: snow 10s linear infinite;
      animation: snow 10s linear infinite;
    }
    @keyframes snow {
      0% {background-position: 0px 0px, 0px 0px, 0px 0px;}
      50% {background-position: 500px 500px, 100px 200px, -100px 150px;}
      100% {background-position: 500px 1000px, 200px 400px, -100px 300px;}
    }
    @-moz-keyframes snow {
      0% {background-position: 0px 0px, 0px 0px, 0px 0px;}
      50% {background-position: 500px 500px, 100px 200px, -100px 150px;}
      100% {background-position: 400px 1000px, 200px 400px, 100px 300px;}
    }
    @-webkit-keyframes snow {
      0% {background-position: 0px 0px, 0px 0px, 0px 0px;}
      50% {background-position: 500px 500px, 100px 200px, -100px 150px;}
      100% {background-position: 500px 1000px, 200px 400px, -100px 300px;}
    }
    @-ms-keyframes snow {
      0% {background-position: 0px 0px, 0px 0px, 0px 0px;}
      50% {background-position: 500px 500px, 100px 200px, -100px 150px;}
      100% {background-position: 500px 1000px, 200px 400px, -100px 300px;}
    }
    </style>
    <p></div>
    <span class="textstyle3"><br/><br/><br/></span>    </div>
      <div class="textstyle1">
        <img src="rc_images/free_digital_scrapbook_sweet_word.png" id="img_75db445f" alt="How can I block someone from accessing custom thank you URL directly? Image-3" title="" />
        </div>
      <div class="textstyle2">
    <span class="textstyle3"><br/><br/></span>    </div>
      <div class="textstyle1">
    <span class="textstyle3">THANK YOU!  Your Rentals Reservation submission has been received. <br/>We'll have your equipment set up and ready for you to pick up when you arrive.<br/><br/></span><span class="textstyle10">Want to purchase your tickets too?</span><span class="textstyle3"><br/>(Tickets will be ready with your rental gear)</span>    </div>
      <div class="textstyle2">
    <span class="textstyle3"><br/></span>    </div>
      <div class="textstyle1">
    <div id="html_35000452">
        <a
          href="javascriptDISABLED:void(
            window.open(
              'https://form.jotform.com/203123998419260',
              'blank',
              'scrollbars=yes,
              toolbar=no,
              width=700,
              height=500'
            )
          )
        "><span style="color:white;">CLICK HERE<BR>to Purchase your Lift Tickets Online
        </span></a></div>
        </div>
      <div class="textstyle2">
    <span class="textstyle3"><br/><br/></span><span class="textstyle3"><br/></span>    </div>
      <div class="textstyle1">
        <img src="rc_images/boarder_giphy.gif" id="img_3ceaa608" alt="How can I block someone from accessing custom thank you URL directly? Image-3" title="" />
        <img src="rc_images/skier_giphy.gif" id="img_6268c31d" alt="How can I block someone from accessing custom thank you URL directly? Image-3" title="" />
        </div>
      <div class="textstyle2">
    <span class="textstyle3">   <br/><br/><br/><br/></span>    </div>
    </div>
    <span class="textstyle11"><br/><br/></span><a href="https://cwsaa.org/links/safety-risk-awareness/"><img src="rc_images/safety_and_risk_awareness.jpg" id="img_137b82f3" alt="How can I block someone from accessing custom thank you URL directly? Image-3" title="" border="0" /></a>
    <span class="textstyle11"><br/></span><span class="textstyle12"> </span></div>
    <div class="textstyle2"></div>
    <div style="clear:both"></div></div></div></div>
    <div style="clear:both"></div></div></div></div>
    <div class="textstyle13"><div id="container_7bce6e97"><div id="container_7bce6e97_padding" ><div class="textstyle2"><span class="textstyle3"> </span><div id="menu_b8e6461"><div  class="menuholder1"><a href="javascriptDISABLED:void(0);">
    <div id="menuentry_71ad0486"  class="style12 menu_b8e6461_mainMenuEntry mobileEntry">
    <div class="style2">
      <span class="textstyle14">Menu &#8801;</span>
    </div>
    </div>
    </a>
    <a href="skihome.html" style="text-decoration:none">
    <div id="menuentry_bfc45e1"  class="style13 menu_b8e6461_mainMenuEntry normalEntry">
    <div class="style14">
      <span class="textstyle15">Home</span>
    </div>
    </div>
    </a>
    <a href="snowreport.html" style="text-decoration:none">
    <div id="menuentry_2a9b76ab"  class="style15 menu_b8e6461_mainMenuEntry normalEntry">
    <div class="style14">
      <span class="textstyle15">Snow Report</span>
    </div>
    </div>
    </a>
    <a href="skihours.html" style="text-decoration:none">
    <div id="menuentry_698f1e7a"  class="style16 menu_b8e6461_mainMenuEntry normalEntry">
    <div class="style14">
      <span class="textstyle15">Hours</span>
    </div>
    </div>
    </a>
    <a href="skicontact.html" style="text-decoration:none">
    <div id="menuentry_3d3bb443"  class="style17 menu_b8e6461_mainMenuEntry normalEntry">
    <div class="style14">
      <span class="textstyle15">Contact</span>
    </div>
    </div>
    </a>
    <a href="javascriptDISABLED:void(0);">
    <div id="menuentry_7308bc43"  class="style18 menu_b8e6461_mainMenuEntry normalEntry">
    <div class="style19">
    </div>
    </div>
    </a>


    <script type="text/javascript" src="rc_images/wsp_menu.js"></script>
    <script type="text/javascript">
    var js_menu_b8e6461= new wsp_menu('menu_b8e6461', 'menu_b8e6461', 10);


    js_menu_b8e6461.createMenuForItem('menuentry_71ad0486', ["  <span class=\"textstyle15\">Home</span> ", '', '',
                                       "  <span class=\"textstyle15\">Snow Report</span> ", 'snowreport.html', '',
                                       "  <span class=\"textstyle15\">Hours</span> ", 'skihours.html', '',
                                       "  <span class=\"textstyle15\">Contact</span> ", 'skicontact.html', '']);
    js_menu_b8e6461.createMenuForItem('menuentry_bfc45e1', []);
    js_menu_b8e6461.createMenuForItem('menuentry_2a9b76ab', []);
    js_menu_b8e6461.createMenuForItem('menuentry_698f1e7a', []);
    js_menu_b8e6461.createMenuForItem('menuentry_3d3bb443', []);
    js_menu_b8e6461.createMenuForItem('menuentry_7308bc43', []);


    </script>
    </div></div><span class="textstyle3">  </span><span class="textstyle3">                                                                            </span><div id="text_7d2d5be8"><div class="textstyle2">  <span class="textstyle16">&#169; 2020 Purden</span>
    </div>
    </div></div>
    <div style="clear:both"></div></div></div></div>
    </div>  </div>
    <div class="textstyle2">
    <span class="textstyle3"><br/></span>  </div>
    </body>
    </html>
    <?php
    }
    // if access is NOT from jotform.com, then redirect the user to the following URL.
    else  {
    header("Location: http://www.purden.com/skihome.html");
    }
    ?>
  • Richie JotForm Support
    Replied on December 3, 2020 at 3:43 AM

    I have tried using cookies to get the referrer however, it seems you would have to set a sessions or cookie in your form to check the referrer.

    <?php

    if(isset($_COOKIE['https://www.jotform.com']))

    {

    Maybe this is the reason why the referrer script is not working.

    It is redirecting to the main page.

    I will try to find another work around if this is possible with the redirect thank you page.