Jump to content


Caspio Ninja
  • Content Count

  • Joined

  • Last visited

  • Days Won


TWIRED last won the day on December 28 2016

TWIRED had the most liked content!


  • Rank
    Advanced Member
  • Birthday May 7

Recent Profile Visitors

2,401 profile views
  1. If its a result page, You could put the code below in the header(Source) authentication needs to be enabled. change the "http://.." to the appropriate URL. Hope this helps.. <div id="myDiv1"></div> <SCRIPT LANGUAGE="JavaScript"> var myDiv1 = document.getElementById("myDiv1"); var branchtype ='[@authfield:Staff_List_Branch_Type]'; //alert(branchtype); if (branchtype=='FS') { myDiv1.innerHTML = "<b><h3><a href=\"http://www.google.com\">Google</a></hr></b>"; }
  2. Hey abelphathot, this might help.. In your original post, if its a checkbox <SCRIPT LANGUAGE="JavaScript"> function Updatestatus(){if (document.getElementById("approved").checked==true){document.getElementById("status")="approved";}else if (document.getElementById("approved").checked==false){document.getElementById("status")="pending";}document.getElementById("caspioform").onsubmit= Updatestatus; </SCRIPT> you need to change to function Updatestatus(){if (document.getElementById("approved").checked=true);{document.getElementById("InsertRecordstatus"
  3. Thanks for taking the time ! Will try the site account settings in the URL format. finally figured out what the problem is after many hours of messing around . Heres what I found out Exampleoriginalimage.jpg (path) is stored in table 1 (file field)lets say fileID is : 0000If the filefield is set to : Upload New File / (Automatically create a unique name) And,If a user uploads a file with the SAME NAME ,originalimage_1.jpg is created but the Original Image fileID NOW will change : originalimage.jpg : 0001 << increased by1 and changedoriginalimag
  4. These type of urls , used to work flawlessly https://c2eku181.caspio.com/dpImages.asp?AppKey=ff384000f093d12f0cad40eab055&file=/IMAGES_/TRIPATWORK/TESTIMAGES/spiderman.jpg Last night it stopped working. it gives "File or Directory Not Found" error We use this type of display of images a lot with our apps. any idea why??? Update It seems to be something to do with the fileID changing. If a field is set to : Upload New File / (Automatically create a unique name) 1) a user uploads a file abc.jpg the first time.2) when the user uplo
  5. Thanks Mathilda, ".. a separate table for history of logs and then create a submission form and receive user's ID and other datapa from authentication fields, then add auto-submit script. After that, you may specify in authentication to redirect user to that datapage and then after form is submitted, redirect user to the user's dashboard. " it worked
  6. Just some pointers:) ---------------------------- 1) One cannot copy a file or image to another table, just by code on the front end (lets say javascript) . Its because of security reasons its disallowed. There has to be user intervention (choose and submit) by the user to do that. 2) in caspio, images/files are not actually stored in the table, A file or image is actually stored in a folder (>> All Assets , Click on Files) >> ONLY a URL Link or path to the file is stored in the table field So basically , you dont need to "copy" the image o
  7. HI Diversity, As Mathilda mentioned, you have to hit "Source" button (in footer) and then paste the code in. Also, Hold down Control key when selecting from the listbox.
  8. This might work.... Create a View with Both Tables - the table/field that will be updated , make editable Choose the view as datasource in the submission form Use the Resizer option in File Field Name , give it the field name you want to copy to. And, Instead of giving resized options, you could just give it the same width and height as the original. attached pic below.
  9. Hi Diversity, If yourlistbox field name is say, "LSTBOX", then you need to :- change it at both places in the script , in your submission form (in footer - configure fields section) to InsertRecordLSTBOX If its an update form then change to EditRecordLSTBOX Destination of Submission form : Same Form Heres a live working example: http://www.tripatwork.com/test-multilistbox-submit.html also attached is my settings for the listbox field element It definitely works, and it works well ! Hope this helps:) Th
  10. This might help... Pure JS http://stackoverflow.com/questions/28545509/display-image-thumbnail-of-image-selected-from-filepicker http://stackoverflow.com/questions/23598175/thumbnail-image-that-pop-when-selected-javascript JQuery/Lightbox Method http://www.lokeshdhakar.com/projects/lightbox2/?u=9
  11. This seemed to work for me. After messing around with it a bit. The trick in the submit form , the destination , do not use "Same Form" opton Use "Go to New Page" and enter the URL of the results datapage Also.. In the Submit form ---------------------- add < ahref="url?cbResetParam=1 > New Search</a> in Header destination : url of results page ( do not use "same Form" option !!) in dropdowns , make sure the onload external parameters is checked and entered. This will keep the drop downs in place after every submission.
  12. Just wanted to share this. Hope it helps somebody. solution to change the value of a label of a particular element in a form (Javascript): ------------------------------------------------------------------------------------------------------------ var labels = document.getElementsByTagName('label'); // 'label' is passed as the argument. To get this argument, First inspect the form element TYPE name in Chrome. for (var i = 0; i < labels.length; i++) { if (labels.htmlFor != '') { var elem = document.getElementById(labels.htmlFor);
  13. What I was looking to do was : change the value of a label (of a particular element) in a form. figured it out. Thanks ! Qtn : Using Javascript, is it possible to change the value of a >> Virtual Field ? If so, How ???? solution to change the value of a label of a particular element in a form: ------------------------------------------------------------------------------------------------------------ var labels = document.getElementsByTagName('label'); // 'label' is passed as the argument. To get this argument, First inspect the f
  14. Just my 2 cents, maybe a shared table , with the parameter values? can then be used witha view or as a lookup table? Thanks
  • Create New...