Jump to content


  • Posts

  • Joined

  • Last visited

adfga's Achievements


Newbie (1/14)



  1. <SCRIPT LANGUAGE="JavaScript"> function check_field() { var fieldname = Arrow1; var max = 10; var min = 1; var myMessage = "Entered value should be more then 0 and less then 11"; fieldname = "InsertRecord" + fieldname; var intmyValue = 0; var myValue = document.getElementById(fieldname).value; if (myValue.length > 0)intmyValue = parseFloat(myValue); else intmyValue = 0; if ((intmyValue>max)||(intmyValue<min)) { alert(myMessage); return false; } } document.getElementById("caspioform").onsubmit=check_field; </SCRIPT> Hi Caspio Evangelist I created a new Data Page same data none of my java scrip.t I added Header & Footers and added your code. Replacing "Interger" with Arrow1 (database name & name on form) It did not return myMessage. Was there anywhere else I should have changed fieldname? Also is this checking the length or value? I want to check value of 10 like $10 not how many digits entered. Not sure I was clear on my post. A real Newby. I reviewed video and yes I have a one to many relationship. Archers(parent) Arrow(child) shot. The tables are setup this way. before Caspio I ran this in Microsoft access.
  2. If you want to run this for go to web page at adfga.ca/test.php and enter archerID as 3 and target 13 and first round put 0 in Cumm and round 0. After first round you should only have to put in the three arrow values
  3. ArrowNew Web Form job is to collect my score as I shoot an archery round that consists of shooting 3 arrows called an end. Going down range score using ArrowNew Web Form. Return to shooting line and do it again until match is over. So usually 10 to 20 rounds. I am new to all this. But I did go thru videos and forum and that worked up to a point but now I am stuck. Problem: Form adds arrow score for end and will add to cumm and increase end by 1 as I go along but they only appear for a second and then replaced by new form. So I have to use back button each time to see results. Not sure to how make page move ID, target, cumm and end count to new form and clear last arrow value Second problem but not as big as one. is arrow value validation an arrow can not have a value greater than 10. and I have tried Rules and javascript but I don't have the coding skill to get this simple task done. So asking for help. To run go to: adfga.ca/test.php This is the coding I added to footer. had to attach files cause paste doesn't work ok I did say I am no expert on any of this. But I have a championship Shoot coming up and wanted to take this live. SCRIPT LANGUAGE.pdf
  • Create New...