I am looking to incorporate some custom jquery to the thank you message page after a form has been submitted. Is this possible? Because when I tried testing this, the page seems to trim out crucial html tags to make things work.
I am looking to incorporate some custom jquery to the thank you message page after a form has been submitted. Is this possible? Because when I tried testing this, the page seems to trim out crucial html tags to make things work.
In that case it sounds like a difference in behavior between versions.
I'm currently on 10.3.1.635
Are you displaying the completed form on the thank you page?
Kind of. In the section where you edit the HTML for the "Thank You" message you can put a script tag and it will execute when that page loads.
As an example,
<div style="text-align: center;"><div style="margin: 25px auto"><h1 style="font-size: 150%; margin-bottom: 30px;">Thank you!</h1><div>Your form has been submitted.</div></div></div> <script> $(document).ready(function(){ console.log('test'); }); </script>
Gave me the following results
Thanks for the quick response.
For some reason when I added my code to the page and save it, the gets deleted after a refresh.
<center><div style="text-align: center;"><b><font size="5">Thank you for your request! </font></b></div></center> <p></p> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <script> $(document).ready(function(){ $("button").click(function(){ $("#div").delay(5000).fadeIn(); $("#loading").delay(1000).fadeIn(); $("#loading").delay(3000).fadeOut(); $("#button1").delay(800).fadeOut(); }); }); </script> <center><button id="button1">Please click here to continue with the request process.</button></center> <div id="div" style="width:90px;height:90px;display:none;background-color:clear;"><input type="submit" value="Searchign complete, please click here to continue..." onclick="window.location='/my/link';" /></div> <div id="loading" style="width:90px;height:90px;display:none;background-color:clear;"><img src="https://upload.wikimedia.org/wikipedia/commons/b/b1/Loading_icon.gif"></div>
Which version of Forms are you running? I copied your code into one of my test forms and couldn't reproduce the issue.
Just to confirm, you are getting the green "Your changes have been saved" message right?
Forms did provide a "your changes have been saved" message for me. I am currently running Version 10.2.0.789.
In that case it sounds like a difference in behavior between versions.
I'm currently on 10.3.1.635
Are you displaying the completed form on the thank you page?
I was able to confirm that its working with 10.3.1. Thanks again.
No problem.
For some added information; if you display the submitted form on the "Thank You" page, you can get fancy with JavaScript and run the code from the form's JavaScript utilizing window.parent and/or window.top functionality to grab the desired page elements.
As an example, I put code in one of my forms that detects when a user opens it from the task list then hides the right pane and expands the window to fit the screen.
I have another form that detects when it is being displayed on the "Thank You" page and hides certain elements to make it more printer-friendly.