ababcock Posted May 20, 2015 Report Share Posted May 20, 2015 I have a signature field on a submission form. I want to require that the name entered matches the name of the user logged in. How can I achieve this? Quote Link to comment Share on other sites More sharing options...
Jan Posted May 22, 2015 Report Share Posted May 22, 2015 Hello ababcock, I am sorry, I am not sure that understand you correctly. A user enters a name (username?) in a field, clicks the "Submit" button and if the entered name is not the name of the logged user, alert message is displayed and a record is not added to the DataBase. Is it correct? If I understand the logic correctly, maybe, you can use a Standard Feature "Stamp a Record with User Profile Data"? Does it work for you? Quote Link to comment Share on other sites More sharing options...
ababcock Posted May 29, 2015 Author Report Share Posted May 29, 2015 I was able to accomplish this by adding an HTML block after the Signature field and filling it with this: <script> document.getElementById('caspioform').onsubmit= function (){ var myname = document.getElementById('InsertRecordSignature').value; if (myname != '[@authfield:User_List_Signature_Name]'){ alert('Not a valid name'); return false; } } </script> If a user tries to enter a name other than the one registered to them, they get the alert 'Not a valid name.' I tested it out, and it works! Thanks! Quote Link to comment Share on other sites More sharing options...
Meekeee Posted June 14, 2021 Report Share Posted June 14, 2021 Hi Everyone - Just an update, Caspio has a new offer, and it's called App Extensions. Electronic Signature is included as well. You can check this link for reference. Quote Link to comment Share on other sites More sharing options...
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.