telepet Posted January 10, 2018 Report Share Posted January 10, 2018 I'm working on a Single Record Update data page. Is it possible to have automatic logout upon hitting the update button? Quote Link to comment Share on other sites More sharing options...
1 MayMusic Posted January 15, 2018 Report Share Posted January 15, 2018 @telepet Then You just need to change the destination after record update to be the logout link. Quote Link to comment Share on other sites More sharing options...
1 Franchiser Posted January 16, 2018 Report Share Posted January 16, 2018 25 minutes ago, telepet said: Thanks @Franchiser. I'm wondering-- can you explain why it necessary to uncheck the "Enable HTLM editor" checkbox? I've experimented with having it checked and things still seems to work ok. @telepet Some users may find enabling the HTML Editor to be a hassle when placing a code such as javascript or css. You need to click the source icon every time once the said code will be used if not, the code will display in a plain text. -Franchiser- Quote Link to comment Share on other sites More sharing options...
1 MayMusic Posted January 16, 2018 Report Share Posted January 16, 2018 Anything that is not placed in SOURCE will be considered as text and you do see all the lines of the script or HTML instead Quote Link to comment Share on other sites More sharing options...
0 Carlson Posted January 11, 2018 Report Share Posted January 11, 2018 Yes, if you are using a report type details datapage, you can set the following: On your details page options settings, uncheck Navigate to next/previous record. On your destination and email settings, set destination after record update dropdown to "Display A Message" Uncheck enable HTML editor Insert this redirect script in the message box: <script> window.location.href = "https://b5.caspio.com/folderlogout"; </script> Just make sure your logout URL is set to the correct data center (example above is using b5). This should automatically logout the user after they update. Quote Link to comment Share on other sites More sharing options...
0 telepet Posted January 11, 2018 Author Report Share Posted January 11, 2018 Thanks @Carlson. I'm using a Single Record Update data page, but will explore building out a Details data page, like the one you mentioned above. That said, I wonder on the feasibility of hiding the default "Update" button, then creating another button that is labeled "Submit", but have it be the logout link on the backend. II've hidden a search button before using this code in the header: <style> #searchID { display:none; } </style> ..and so far I seem to be able to hide the Submit button by replacing #searchID with #Mod0EditRecord. Now I think I need to find out how to make a button that both submits and logs out the user... I'll update this thread once I've explored a bit.... Thanks again! Quote Link to comment Share on other sites More sharing options...
0 telepet Posted January 15, 2018 Author Report Share Posted January 15, 2018 Thanks @MayMusic for the information. I've since created a Details datapage that summarize the user input and has two buttons-- one that allows them to go back to the Sincle Record Update page, and another button (labled "Confirm Submission") that actually logs out the user. Depending how this solution works in real life, I may end up using your much simpler solution. Thanks again. Quote Link to comment Share on other sites More sharing options...
0 Franchiser Posted January 16, 2018 Report Share Posted January 16, 2018 21 hours ago, telepet said: Thanks @MayMusic for the information. I've since created a Details datapage that summarize the user input and has two buttons-- one that allows them to go back to the Sincle Record Update page, and another button (labled "Confirm Submission") that actually logs out the user. Depending how this solution works in real life, I may end up using your much simpler solution. Thanks again. Hi Telepet, All suggestions will work, but to put a little bit of spice. You can use time delay before logging out automatically. <script> setTimeout(function () { window.location.href = "https://b5.caspio.com/folderlogout"; }, 3000); </script> Try to have this code in your destination after record submit, just right under the display message. Please make sure you uncheck the "Enable HTML editor" before placing the code. -Franchiser- Quote Link to comment Share on other sites More sharing options...
0 telepet Posted January 16, 2018 Author Report Share Posted January 16, 2018 Thanks @Franchiser. I'm wondering-- can you explain why it necessary to uncheck the "Enable HTLM editor" checkbox? I've experimented with having it checked and things still seems to work ok. Quote Link to comment Share on other sites More sharing options...
0 telepet Posted January 17, 2018 Author Report Share Posted January 17, 2018 Thanks for the explanation @Franchiser and @MayMusic. Very helpful! Quote Link to comment Share on other sites More sharing options...
0 MayMusic Posted January 19, 2018 Report Share Posted January 19, 2018 You are welcome Quote Link to comment Share on other sites More sharing options...
0 kimburlyz Posted September 21, 2018 Report Share Posted September 21, 2018 On 1/16/2018 at 12:48 PM, Franchiser said: Hi Telepet, All suggestions will work, but to put a little bit of spice. You can use time delay before logging out automatically. <script> setTimeout(function () { window.location.href = "https://b5.caspio.com/folderlogout"; }, 3000); </script> Try to have this code in your destination after record submit, just right under the display message. Please make sure you uncheck the "Enable HTML editor" before placing the code. -Franchiser- Thank you for this question and the answers because this is what I'm looking for, however, I'm trying to apply this to a Form instead and it's not quite working. Let me explain... 1. Authentication Page: User goes to a web page in which they must "authenticate" a code. This is a Caspio Embedded data page with Authentication. 2. Redirected based on Code: Depending on the code they are redirected to a specific page, which is actually a Form. (So at this point, they are logged into Authentication). 3. Enrollment Form: User completes the form (an embedded Caspio form). 4. Submit: Once they hit Submit, there is a Display Message and an is Email sent. I tried the code above and it does redirect, but bypasses the Authentication Page. So they are never "logged out". I need it to log out so they can enter a new code. Unfortunately I can only set the automatic logoff to a minimum of 15 minutes. Any suggestions would be greatly appreciated. Thank you, Kim Quote Link to comment Share on other sites More sharing options...
0 kimburlyz Posted September 21, 2018 Report Share Posted September 21, 2018 (edited) I figured out my issue and was able to use the code to automatically log the user out. Now my only issue is... If the user enters a code that redirects them to a completely different "external site" and they return back to the "Authentication Pge" in less than the 15 minute automatic logoff time limit, it redirects them back to that "external site". So my issue is not 100% resolved. Edited September 21, 2018 by kimburlyz Revised response on resolution. Quote Link to comment Share on other sites More sharing options...
0 LWSChad Posted September 21, 2018 Report Share Posted September 21, 2018 If you have updated your DataPages to use the subdomain for your account in the deploy code, the logout link now uses the account subdomain for your account. Rather than b5.caspio.com/folderlogout try ******.caspio.com/folderlogout where ****** is your Also, see: https://howto.caspio.com/deployment/caspio-site-vs-account-subdomain-deployment/ Hope this helps Quote Link to comment Share on other sites More sharing options...
0 kimburlyz Posted September 21, 2018 Report Share Posted September 21, 2018 Thanks Chad! That is exactly what I did and it resolved it...however. If the user enters a code that redirects them to a completely different "external site" and they return back to the "Authentication Pge" in less than the 15 minute automatic logoff time limit, it redirects them back to that "external site". So my issue is not 100% resolved. Quote Link to comment Share on other sites More sharing options...
Question
telepet
I'm working on a Single Record Update data page. Is it possible to have automatic logout upon hitting the update button?
Link to comment
Share on other sites
14 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.