Jump to content


Caspio Evangelist
  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by Vitalikssssss

  1. Hi @JMR21, The above code needs to be updated since now all Caspio Datapages have AJAX and special event handler "DataPageReady". You may try the following updated JavaScript: <script> document.addEventListener('DataPageReady', assignEvent); function formatAsDollars(el) { el.value = el.value.replace(/[^\d]/g,'').replace(/(\d\d?)$/,'$1').replace(/^0+/,'').replace( /\d{1,3}(?=(\d{3})+(?!\d))/g , "$&,"); el.value = el.value ? '$' + el.value : ''; } function assignEvent(){ let fields = ["Field_1", "Field_2"]; //specify your fields here fields.forEach(element => {
  2. Hi @Bradl, Caspio Payment processor do not have an option for recurring charges. You may check with Professional Services Team of Caspio if they can built with custom programming. Regards, vitalikssssss
  3. Hi @jrifkin, It is possible but you need to follow certain naming convention: 1. Files fields you need to name them as: File_1, FIle_2, File_3 ... 2. File size fields should be named as: File_1_size, File_2_size, File_3_size ... Here is a slightly modified JavaScript provided by @Hastur: <script> document.addEventListener('DataPageReady', fileInputEvent) function fileInputEvent() { const fileFields = ['File_1', 'File_2']; //add more file fields if needed fileFields.forEach(el=>{ document.querySelector(`#InsertRecord${el}`).addEventListener('change
  4. Hi @randallsla, There is no feature in Caspio Authentication which could lock the account after certain number of unsuccessful attempts. You may truck number of login attempts with User Logs features. You can restrict the access to the Datapages for certain IP`s if you notice some unusual activity of under some IP address. Hope this helps. Regards, Vitalikssssss
  5. Hi @mhand, You may try to use the following JavaScript snippet: <script> document.addEventListener('DataPageReady', eventHandler); function eventHandler(){ document.querySelector('input[name="cbParamVirtual4"]').addEventListener('change', copyFields); document.querySelector('input[name="cbParamVirtual5"]').addEventListener('change', copyFields); } function copyFields(e){ const element = e.target.name; if(element === "cbParamVirtual4"){ document.querySelector('#cbDSField1').value = e.target.value; } else if (element === "cbParamVirtual5") { document.qu
  6. Hi @Elderberg, JS snippet looks correct. Perhaps you have some Triggered action which interfere with updated records. If not, you can share a whole snippet, so we could help you to narrow down the issue. Regards, vitalikssssss
  7. Hi @CraigSZ, Here is a page which has a Chart page dynamically rendered depending on which button was clicked. You would need to have some div element which would serve as a container for updated Datapage. <div id="datapage-container"></div> Here is a code which I have in Datapage. 1. HTML block with buttons: <div class="buttons"><input id="[@field:Name]" type="button" value="Sales in Eastern region"></div> <br> <div class="buttons"><input id="[@field:Name]" type="button" value="Sales in Central region"></div> 2
  8. Hi @Elderberg, I have recently found that you can get suffix from DataPage event. <script type="text/javascript"> document.addEventListener('DataPageReady', function (event) { let suffix = event.detail.uniqueSuffix; console.log(suffix); }); </script> Regards, vitalikssssss
  9. Hi @Chrille, The issue is caused by the following line of code. You can simple removed it in order to make it work. document.removeEventListener('DataPageReady', drawSignature); Regards, vitalikssssss
  10. Hi @Libby, Triggered Action have 10,000 records limit per run and same applies to Application Tasks. You will not be able to run a Task on table which has 61,000 records https://howto.caspio.com/tables-and-views/triggered-actions/
  11. Hi @aquintanilla, Here is possible way how you can achieve the desired functionality. 1. Add Virtual field to the form and set a default value URL to which user will be re-directed after submit. 2. Add the following snippet in Datapage Header. Make sure you make changes in lines with comment ***Change <script type="text/javascript"> document.addEventListener('DataPageReady', creatBtn); // function creatBtn () { // Hides the Virtual field const link = document.querySelector("#cbParamVirtual1"); //***Change Virtual1 if needed link.style.display = 'none'; //C
  12. Hi @ahmedramadan, Perhaps you may try the following code snippet: <script type="text/javascript"> document.addEventListener('DataPageReady', initGeolocation); function initGeolocation() { if(navigator.geolocation) { // Call getCurrentPosition with success navigator.geolocation.getCurrentPosition(success); } else { alert("Sorry, your browser does not support geolocation services."); } } function success(position) { /
  13. Hi @MrRee, I think it is better to raise a ticket for the support department: https://support.caspio.com/ Regards, vitalikssssss
  14. Hi @Elderberg, Yes, it is possible. Here is a topic from Stackoverflow with code sample: https://stackoverflow.com/questions/979975/how-to-get-the-value-from-the-get-parameters Regards, vitalikssssss
  15. Hi @Darnellhood123, You can update any fields with Triggered action. Makes sure you select #inserted if you would like to update same record which was submitted or updated. Regards, vitalikssssss
  16. Hi @HughOD, This method works if you disabled the Responsive feature.
  17. Hi @HughOD, This method works only with Responsive option disabled. If you would like to preserve responsive design of Datapages you may try using the following code in HTML blocks: HTML block #1 </header><div style="display:none;"><header> HTML block #2 </footer></div><footer> Cheers, vitalikssssss
  18. Hi @CraigSZ, You may utilize the concept explained in this post: Hope this helps. Regards, vitalikssssss
  19. Hi @HughOD, I had a similar issue before and it is some kind of limitation of the Free version of Caspio. I have raised a ticket regarding this and Support rep informed me that there was some security check which run behind the scene and affected the loading time. You can raise a ticket here: https://support.caspio.com/ Regards, vitalikssssss
  20. Hi @NickO, It would not be possible to write some generic code which would be easy to tweak, because Datapages with Groupping enabled has difference in HTML structure. I have created a sample based on your screenshots and my understanding of the HTML structure. I have added a Total and Aggregation field which would be used as a criteria for hiding. The report looks like the following without Javascript: I have set the criteria in JS code to hide Category name and all rows within a group if Total is less than 70, so the Datapage looks like the following: The JavaSc
  21. Hi @BFuchs, You need to make sure that you select Date and Time type of precision in the filtering settings. Also, you need to setup a correct logic for filtering within a range of Date&Time values: You may use a Submission Form which would pass a parameters from Virtual fields to Report Datapage. Submission form should have separate Virtual fields for Date and Time input. Calculated value can be used to concatenate Date and Time input and pass it as a parameter to the next form. Finally, you need to create a Report Datapage with predefined filtering cri
  22. @NickO hi! I think you have a different setup on the Datapage compare to mine test page. Perhaps, you can send a screenshot of the table (without JS), so I could build something similar and test the JS further. Regards, vitalikssssss
  23. Hi @streetsmart, The post with Signature Pad solution has been updated and now supports AJAX and Responsive features. Regards, vitalikssssss
  24. Hi @Melodybelle, Original post has been updated recently and it includes now a solution for two signature pads. Let me know if you run into an issue while implementing this solution. Thanks, vitalikssssss
  25. Hi @Chrille, The post with Signature Pad solution has been updated and now supports AJAX and Responsive features. Let me know if you run into some issues while implementing solution from updated post. Thanks, vitalikssssss
  • Create New...