Cameron Posted August 10, 2015 Report Share Posted August 10, 2015 Hi everyone! I have a Submission form, and I would to display an animation with "Loading..." text while the data is submitted. Is it possible in Caspio? Any ideas are very much appreciated! Thank you for your time! Quote Link to comment Share on other sites More sharing options...
0 iren Posted August 10, 2015 Report Share Posted August 10, 2015 Hi Cameron, You can paste the respective snippet inside the HTML Header and HTML Footer section. Header: <h1 id="loadingTitle" style="display: none">Loading...</h1> Footer: <script> var v_appkey = 'appkey_number', v_appkeyInputs = document.getElementsByName('AppKey'), v_appKeyInput = null; for(var v_i = 0; v_i < v_appkeyInputs.length; v_i++){ if(v_appkeyInputs[v_i].value == v_appkey){ v_appKeyInput = v_appkeyInputs[v_i]; break; } } if(v_appKeyInput){ var v_formNode = null, v_tempNode = v_appKeyInput.parentNode; do{ v_formNode = v_tempNode; v_tempNode = v_tempNode.parentNode; }while(v_formNode && v_formNode.nodeName.toLowerCase() != 'form'); if(v_formNode){ v_formNode.onsubmit = function(){ var v_title = document.getElementById('loadingTitle'); if(v_title){ v_title.style.display = ''; } }; } }</script> Hope it helps. Quote Link to comment Share on other sites More sharing options...
0 Cameron Posted August 11, 2015 Author Report Share Posted August 11, 2015 Hi Iren, Thank you for your time! I am afraid, I don't understand what is 'appkey_number' and 'AppKey'. I have tried several variants, but no animation is displayed. Probably, I missed something. Quote Link to comment Share on other sites More sharing options...
0 iren Posted August 12, 2015 Report Share Posted August 12, 2015 Hello Cameron, Please change the 'appkey_number' value to the number of your DataPage AppKey. Does it work for you? Quote Link to comment Share on other sites More sharing options...
0 Cameron Posted August 13, 2015 Author Report Share Posted August 13, 2015 And I do not change the 'AppKey', if I understand correctly. Thank you for your time and for your explanation! It works! Quote Link to comment Share on other sites More sharing options...
0 Xiang Posted August 13, 2015 Report Share Posted August 13, 2015 Good morning, I think, the following script can do the same. The code for Header: <h1 id="loadingTitle" style="display: none">Loading...</h1> <div id="mainText" style=""> The code for Footer: </div> <script> document.getElementById('caspioform').onsubmit = function() { document.getElementById('loadingTitle').style.display = ''; document.getElementById('mainText').style.display = 'none'; } </script> I'm sorry, I don't understand for what the 'appkey_number' is used in the first script? Quote Link to comment Share on other sites More sharing options...
0 iren Posted August 13, 2015 Report Share Posted August 13, 2015 Hi Xiang, The script with 'appkey_number' is used when you implement a few DataPages on the web source. Hope it helps. Quote Link to comment Share on other sites More sharing options...
0 NailDyanC Posted June 26, 2021 Report Share Posted June 26, 2021 Hi, just to update this post and add in the previous comments above, you may also consider checking these links: https://forums.caspio.com/topic/19994-dynamic-progress-bar/?tab=comments#comment-56794https://forums.caspio.com/topic/6492-progress-bar-needed/?tab=comments#comment-20304https://forums.caspio.com/topic/4559-progress-bar-during-submission/?tab=comments#comment-14320 Quote Link to comment Share on other sites More sharing options...
Question
Cameron
Hi everyone!
I have a Submission form, and I would to display an animation with "Loading..." text while the data is submitted. Is it possible in Caspio?
Any ideas are very much appreciated!
Thank you for your time!
Link to comment
Share on other sites
7 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.