Jump to content


Caspio Ninja
  • Posts

  • Joined

  • Last visited

  • Days Won


Posts posted by wgalliance

  1. I would like to hide a column in a tabular report IF it meets a specific criteria. I have looked at several forum posts including the following: http://howto.caspio.com/tech-tips-and-articles/advanced-customizations/how-to-dynamically-change-the-background-of-a-results-page/?_ga=1.209653078.530491687.1457713192 and

     Currently I have the following script added to the footer:

    var isi = document.getElementById("visi[@field:CFC_zones_OPM_Name]");
    if('[@authfield:User_Table_WGAusers_Access_Level]' == 'Finance'){
    isi.style.display = 'none';

    Help would be appreciated.

  2. The fields are number fields and users need to input those three figures, management + fundraising + total revenue. Sometimes they will enter the number with a dollar sign and I want to remove that if it happens. My script is then calculating a percentage based on the figures they are entering on the page and then displaying that percentage to them.

    So I need something that can remove any currency symbols or commas because it conflicts with my other script and the math doesn't calculate correctly.

  3. I have three fields in an Update Datapage (ManagementExpenses, FundraisingExpenses, and TotalRevenue) that I need to format as only numbers (no currency symbols), if someone enters $11,500.51 it would render 11500.51 or $1,500,000 would render as 1500000.

    I then use the numbers on a separate onchange function that calculates a % based on the three numbers in that same page.

    Could anyone help me with a script to remove any currency symbols if the user inputs them?

    I appreciate the help!

  4. I have a script that formats the phone number input to a particular mask, which works great.

    There are three fields in this Datapage that need the same masking script and currently I have copied the code three times and simply changed the field that it refers to (code below). I am wondering if there is a way to add an array to this so that if you update either the Finance_Phone, Primary_Phone or Additional_phone the script will run. 

    That way the full script is on the page only once and not copied three times.


    function f_a(v_id)
    return document.getElementById(v_id);
    f_a('EditRecordFinance_Phone').maxLength = 14;
    f_a('EditRecordFinance_Phone').onkeyup = function(v_e)
    v_e = v_e || window.event;
    if (v_e.keyCode >= 65 && v_e.keyCode <= 90){
    this.value = this.value.substr(0, this.value.length - 1);
    return false;
    }else if (v_e.keyCode >= 37 && v_e.keyCode <= 40){
    return true;
    var v_value =(this.value.replace(/[^\d]/g, ''));
    if (v_value.length==7) {
    this.value = (v_value.substring(0,3) + "-" + v_value.substring(3,7));}
    else if(v_value.length==10){
    this.value = ("(" + v_value.substring(0,3) + ")" + v_value.substring(3,6) + "-" + v_value.substring(6,10));


  5. Hi MayMusic,

    I have had this script working on my pages for a while now. I recently changed some of my workflow so that the webpages now include a navigation menu that is a datapage in and of itself. This has made some of the script stop working. I've used this tutorial recommended by support to help me troubleshoot some issues.

    How can I rewrite this simple script which had been working prior to deploying a second datapage:

    if (document.getElementById('EditRecordAppLocked').checked){


    Any thoughts about how to use this with an .onload function that can then call the correct datapage by adding  document.forms[1].onload to the script....


  6. I have used the Caspio tutorial for adding a digital signature (http://forums.caspio.com/index.php?/topic/4693-js-adding-a-digital-signature-to-a-submission-form/). The signature is working great, but I want a way to disable it if the user has already "signed" their submission. I can use rules to hide the signature portion, but I cannot submit the page without the user submitting a new signature.

    This is the code for the signature capture:

    <canvas class="pad" width="218" height="55" style="margin: 0px 0px 0px 100px;  border-style: solid; border-width: 1px; border-color: #bbbbbb #dbdfe6 #e3e9ef #e2e3ea; -webkit-border-radius: 1px; -moz-border-radius: 1px; -o-border-radius: 1px; border-radius: 1px; -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; background-color: #FFFFFF;"></canvas></br>
    <span style="margin: 0px 0px 0px 264px;"><input type="reset" class="clearButton" value="Clear"></span>
    <input type="hidden" name="output" class="output">
    <script type="text/javascript">
    $(document).ready(function () {
      $('#caspioform').signaturePad({drawOnly : true});
    $("#cb_sign_wrapper form").submit(function(){
    $("#InsertRecordSignature")[0].value = $("#cb_sign_wrapper .output")[0].value;

    I want to disable the signature if the field has already been completed. Has anyone done this already and could provide the code?

  7. I have a single record update form deployed on my webpage which contains an iframe inside an html block on the parent page. This iframe collects a signature. I need help getting the signature to pass to the parent page once the iframe has been submitted.

    How can I pass a parameter from an iframe to the parent page it is deployed in?

  8. In some cases this would work, but in many of my datapages I already have rules and conditions applied that do not allow me to to then disable fields.

    For the first time a user access the datapage, I have rules that set required fields, hide sections, etc. However, once they submit the page, a checkbox changes to "submitted" when that field is checked, if the user goes back to look at their information, I want to disable the ability for them to submit NEW changes to the datapage. I want to lock it from any further changes. Thus I do need JS because I cannot use the disable the fields  in the rules section since they are already being used for other conditions.

  9. Thanks! That worked beautifully! I used the code from the Caspio tutorial which is: 

    <div class="sigPad signed"> <div class="sigWrapper">
    <canvas height="55" width="198" class="pad"></canvas></div>
    var sig = eval("[@field:Signature]".replace(/"/g, '"'));
    $(document).ready(function () {

    for some reason this section of code (specifically for displaying) did not work on my details page.

    Thank you for sharing your solution!

  10. I have followed the Caspio instructions for setting up a digital signature pad (http://forums.caspio.com/index.php?/topic/4693-js-adding-a-digital-signature-to-a-submission-form/



    I have used this code on two separate pages, one submission form, where the signature capture works. The second is on a details page where I both want to capture the signature (if previously not received) and I want to display the signature (if already signed). On this page, the capture portion works but I cannot get the display portion to work. So, if it was previously signed I am not able to see the signature.

    Here is the deployed page: http://www.wgaportal.org/reviewcertifications.html?ApplicationID=226

    Help would be appreciated.

  11. I am having trouble with this simple if statement. I would like to update a checkbox field if a separate field is "Final Staff Review".

    The script I have is:


    function = applocked(){
    if (document.getElementById("EditRecordReviews_ReviewStage").value == "Final Staff Review")
    document.getElementById('EditRecordApplication_Detail_AppLocked').checked = true;} 
    else {
    document.getElementById('EditRecordApplication_Detail_AppLocked').checked= false;
    document.getElementById("caspioform").onload = applocked;



    Am I missing something? The field is a Yes/No field and it is on the datapage as a checkbox field. I also have several formulas deployed on this page, could that be impacting this?

    This is currently not working.

  12. I would like to conditionally change the color of a display field on a detail page.

    I have a set of 9 fields that are all set as display fields. If the value is "Incomplete" I would like it to show up in RED text, otherwise nothing changes. 

    I have read several of the forums but most of them refer to tabular reports or a field which the user updates. This is simply a details page with a display field.

    Thanks in advance,

  • Create New...