<html> <head> <title>The Request</title> <script type="text/javascript"> <!-- // Form validation code will come here. //--> </script> </head> <body> <h1>The Request</h1> <form action="/cgi-bin/test.cgi" name="myForm" onsubmit="return(validate());"> <table cellspacing="2" cellpadding="2" border="1"> <tr> <td align="right">Id</td> <td><input type="number" name="Id" /></td> </tr> <tr> <td align="right">Course Number</td> <td><input type="number" name="CourseNumber" /></td> </tr> <tr> <td align="right">Description</td> <td><input type="text" name="Description" /></td> </tr> <tr> <script> </script> <td align="right">Distance Education</td> <td id="costcontainer" onchange="Process(this.options[this.selectedIndex].value)"> <label><input id="checkbox" type="checkbox" name="form[date]" value = "0.0" updatecost="50" onChange="onToggle();"></input> </label></td> </tr> <tr> <td align="right">Additional Marks</td> <td><input type="number" name="AddMarks" /></td> </tr> </table> </form> <p> <td align="right">Number of Courses</td> <td><input type="number" name="NumberCourses" id="NumCourses" /></td> <script type="text/javascript"> document.getElementById("NumCourses").value = 0 </script> <td align="right">Total Cost</td> <td><input type="text" id="total" name="total" updatecost=5 0></td> </script> </p> <b>Reasons: </b><input type="radio" name="reason" value="Doctor"> Doctor's Note <input type="radio" name="reason" value="LackWork"> Lack of Work <input type="radio" name="reason" value="Compassion"> Some Compassion <p> <td> <br> <input type="submit" value="Go For It" /> <input type="reset" value="Clear and Reset" /></td> <td align="right"></td> <td> <select name="Use"> <option value = "-40" selected>First Time User</option> <option value = "1">Frequent Flyer</option> <option value = "2">Buying a Degree</option> </select> </div> </p> <p> <h4>Summary of Your Request(s)</h3> <p><textarea rows="6" cols="60"> </textarea></p> <p> <h4>Danger Range</h3> <p><textarea rows="6" cols="60"> </textarea></p> <script> // on toggle method // to check status of checkbox function onToggle() { var cost = document.getElementById('checkbox'); var amount = 0; amount += cost.checked ? parseFloat(cost.getAttribute('updatecost')) : 0; document.getElementById('total').value = amount; } </script>
We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy. Accept Learn more