Guest TomCat86 Posted May 2, 2010 Share Posted May 2, 2010 i have created a web form, however the user now wants one of the drop down sections to be check boxes so more than one option can be submitted. if anyone knows how to do this & could show me it would be most appreciated because i have tried to do it with no success. here is the code for the page as it stands. it is the drop down box for action taken that i would like to be a changed to check box options.RegardsTom<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office"> <head> <style type="text/css"> .divScroll-1 { height:100px; width:200px; overflow:scroll; } </style> <title></title> <link href="default4.css" rel="stylesheet" type="text/css"> <link rel="stylesheet" type="text/css" href="default4.css"> <script type='text/javascript' src='menuscript2.js'></script> <style type="text/css">.style4 { text-align: right;} .style2 { font-size: small;}</style><script type="text/javascript">/************************************************ Drop down menu w/ description- © Dynamic Drive (www.dynamicdrive.com)* This notice must stay intact for use* Visit http://www.dynamicdrive.com/ for full source code***********************************************///1) CUSTOMIZE TEXT DESCRIPTIONS FOR LINKS ABOVEvar thetext1=new Array()thetext1[0]=""thetext1[1]=""thetext1[2]=""thetext1[3]=""thetext1[4]=""/// You may define additional text arrays if you have multiple drop downs:var thetext2=new Array()thetext2[0]=""thetext2[1]=""thetext2[2]=""thetext2[3]=""var thetext3=new Array()thetext2[0]=""thetext2[1]=""thetext2[2]=""thetext2[3]=""// Now, see 2) below for final customization stepfunction displaydesc(which, descriptionarray, container){if (document.getElementById)document.getElementById(container).innerHTML=descriptionarray[which.selectedIndex]}function jumptolink(what){var selectedopt=what.options[what.selectedIndex]if (document.getElementById && selectedopt.getAttribute("target")=="newwin")window.open(selectedopt.value)elsewindow.location=selectedopt.value}displaydesc(document.form1.select1, thetext1, 'textcontainer1')displaydesc(document.form2.select2, thetext2, 'textcontainer2')displaydesc(document.form3.select3, thetext3, 'textcontainer3')displaydesc(document.form4.select4, thetext4, 'textcontainer4')displaydesc(document.form5.select5, thetext5, 'textcontainer5')displaydesc(document.form6.select6, thetext6, 'textcontainer6')displaydesc(document.form7.select7, thetext7, 'textcontainer7')displaydesc(document.form8.select8, thetext8, 'textcontainer8')displaydesc(document.form9.select9, thetext9, 'textcontainer9')displaydesc(document.form10.select10, thetext10, 'textcontainer10')</script> </head> <body><b> <div style="position: absolute; width: 82px; height: 95px; z-index: 1; left: 488px; top: -6px" id="layer1"> <img alt="" src="../../Images/Logo-%20fish%20only.JPG" width="80" height="75"></div></b><br><b> <div style="position: absolute; width: 100px; height: 86px; z-index: 2; left: 15px; top: 1px" id="layer2"> <img alt="" src="../../Images/Logo%20LP%20Hub.JPG" width="470" height="73"></div> </b><br><br> <span class="style2"> <b> <div id="wrapper"><div id="contentheader" align="left"><br />Please use this form to report any investigations:</div> <table id="mytblform" bgcolor="white" style="text-align:Left; width: 600px; border:thin #7DC242 dotted; left: 195px; top: 176px;" border="0" cellpadding="2" cellspacing="2" bgcolor="#FFFFFF"> <tbody> <tr> <td style="border-right:thin #7DC242 dotted;">Investigator Name: </td> <td style="width: 374px" ><SELECT id="Requested_By" name="Requested_By"> <OPTION selected>Please Select <option value="Iain Parker">Iain Parker</option><option value="Mike Cannon">Mike Cannon</option><option value="Mark Hough">Mark Hough</option><option value="Peter Higginbottom">Peter Higgi</option>nbottom<option value="Jaci Andrews">Jaci Andrews</option><option value="Mark Kernohan">Mark Kernohan</option><option value="Rob Beastall">Rob Beastall</option><option value="Pat Austin">Pat Austin</option><option value="Stuart Richards">Stuart Richards</option><option value="Matt Hopley">Matt Hopley</option><option value="Adrian O'Kane">Adrian O'Kane</option><option value="Marj Sharp">Marj Sharp</option><option value="Dave Richards">Dave Richards </option><option value="Greg Feret">Greg Feret</option><option value="Chris Timms">Chris Timms</option><option value="Claire Rushton">Claire Rushton </option><option value="Andy Lawson">Andy Lawson</option><option value="Mark Dixon">Mark Dixon</option><option value="Steve Bond">Steve Bond</option><option value="Noel Barnes">Noel Barnes</option><option value="John Flood">John Flood </option><option value="Emma Stacey">Emma Stacey</option><option value="Barry Retalic">Barry Retalic </option><option value="Andrew Rees">Andrew Rees</option><option value="Ian MacDonald">Ian MacDonald</option><option value="Sean Bowen">Sean Bowen</option></SELECT></td> </tr> <tr> <td style="border-right:thin #7DC242 dotted;">Store Name:</td> <td style="width: 374px" ><input id="Store_Name" name="Store_Name" size="25"></td> </tr> <tr> <td style="border-right:thin #7DC242 dotted;">Store Number:</td> <td style="width: 374px" ><input id="Store_No" name="Store_No" size="25"></td> </tr> <tr> <td style="border-right:thin #7DC242 dotted;">Arena Number:</td> <td style="width: 374px" ><input id="Arena_No" name="Arena_No" size="25"></td> </tr> <tr> <td style="border-right:thin #7DC242 dotted;">Case Number:</td> <td style="width: 374px" ><input id="Case_No" name="Case_No" size="25"></td> </tr> <tr> <td style="border-right:thin #7DC242 dotted;">Total Incident Value:</td> <td style="width: 374px" ><input id="Incident_Value" name="Incident_Value" size="25"></td> </tr> <tr> <td style="border-right:thin #7DC242 dotted;">Total Recovered:</td> <td style="width: 374px" ><input id="Total_Recovered" name="Total_Recovered" size="25"></td> </tr> <tr> <td style="border-right:thin #7DC242 dotted;">Case Open/Closed:</td> <td align="left" style="height: 26px"><SELECT id="Case_Status" name="Case_Status"><option selected="selected">Please Select Incident Type </option><option value="Closed">Case Closed</option><option value="Case Update">Case Update</option><option value="Case Open">Case Open</option></select> </td></tr> </tr> <tr> <td style="border-right:thin #7DC242 dotted;">Action taken against suspect:</td> <td align="left" style="height: 26px"><SELECT id="Action_Taken" name="Action_Taken"><option selected="selected">Please Select Action Taken</option><option value="Suspended">Suspended</option><option value="Dismissed">Dismissed</option><option value="Resigned">Resigned</option><option value="Arrested">Arrested</option><option value="Admitted">Admitted</option></select> </td></tr> </tr> <tr> <td style="border-right:thin #7DC242 dotted;">Relevant to Brett's Case Sheet: </td> <td style="width: 374px"><select name="Case_Sheet" id="Case_Sheet" onchange="showmenu()"> <option selected="selected">Please Select... </option><option value='Yes'>Yes</option><option value='No'>No</option> </select></td> </tr> </tbody> </table><!--Availability Div Element--><div id='Yes' class='topbar' style="left: 194px; top: 494px"><script type="text/vbscript">function Availcheckform()dim intError, strErrorintError = 0strError = "Please ensure you have completed all information before submitting this form." & vbcrlf & vbcrlfif len(document.all.Requested_By.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Your Full Name" & vbcrlfElsedocument.all.MainReqBy.value = document.all.Requested_By.valuedocument.all.MainCase_Sheet.value = document.all.Case_Sheet.valueend ifif len(document.all.Store_Name.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Store Name" & vbcrlfElsedocument.all.MainStoreName.value = document.all.Store_Name.valuedocument.all.MainStore_Name.value = document.all.Store_Name.valueend ifif len(document.all.Store_No.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Store Number" & vbcrlfElsedocument.all.MainStoreNo.value = document.all.Store_No.valuedocument.all.MainStore_No.value = document.all.Store_No.valueend ifif len(document.all.Arena_No.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Arena Number" & vbcrlfElsedocument.all.MainArenaNo.value = document.all.Arena_No.valuedocument.all.MainArena_No.value = document.all.Arena_No.valueend ifif len(document.all.Case_No.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Case Number" & vbcrlfElsedocument.all.MainCaseNo.value = document.all.Case_No.valuedocument.all.MainCase_No.value = document.all.Case_No.valueend ifif len(document.all.Incident_Value.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Incident Value" & vbcrlfElsedocument.all.MainIncidentValue.value = document.all.Incident_Value.valuedocument.all.MainIncident_Value.value = document.all.Incident_Value.valueend ifif len(document.all.Total_Recovered.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Recovered Value" & vbcrlfElsedocument.all.MainTotalRecovered.value = document.all.Total_Recovered.valuedocument.all.MainTotal_Recovered.value = document.all.Total_Recovered.valueend ifif len(document.all.Case_Status.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Case Status" & vbcrlfElsedocument.all.MainCase_Status.value = document.all.Case_Status.valuedocument.all.MainCase_Status.value = document.all.Case_Status.valueend ifif len(document.all.Action_Taken.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Action Taken" & vbcrlfElsedocument.all.MainAction_Taken.value = document.all.Action_Taken.valuedocument.all.MainAction_Taken.value = document.all.Action_Taken.valueend ifif len(document.all.Type_Incident.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Incident Type" & vbcrlfElsedocument.all.MainType_Incident.value = document.all.Type_Incident.valuedocument.all.MainType_Incident.value = document.all.Type_Incident.valueend ifif len(document.all.Exec_Name.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Exec Name" & vbcrlfElsedocument.all.MainExec_Name.value = document.all.Exec_Name.valuedocument.all.MainExec_Name.value = document.all.Exec_Name.valueend ifif intError > 0 thenmsgbox strError, vbokonly, "Form Incomplete..."elsedocument.all.recipient.value = "thomas.horner@asda.co.uk, ian.mcdonald@asda.co.uk, john.flood@asda.co.uk, julie.barff@asda.co.uk"document.all.AvailbtnSubmit.disabled = truedocument.all.AvailbtnSubmit.value = "Please Wait While We Submit Your Information"document.all.feed_form.submit()end ifend function</script><ul id='mylist' style="width: 582px"><li id='Measureli' style="width: 580px"><table border="0" align="right" style="width: 159%"><tr align="center"> <td align="right" style="width: 110px; height: 26px;">Incident Type:</td><td align="left" style="height: 26px"><SELECT id="Type_Incident" name="Type_Incident"><option selected="selected">Please Select Incident Type </option><option value="Ethics">Ethics</option><option value="Exec Involvment">Exec Involvment</option><option value="Theft - More than £10,000">Theft - More than £10,000</option><option value="Fraud - More than £25,000">Fraud - More than £25,000</option><option value="Corruption">Corruption</option><option value="Embezzlement">Ebezzlement</option><option value="Bribery">Bribery</option><option value="Insurance Fraud">Insurance Fraud</option><option value="Conflict Of Interest">Conflict Of Interest</option><option value="Procedural Compliance Violation">Procedural Compliance Violation</option></select> </td></tr></table></li><li id='OpLevelli' style="width: 580px"><table border="0" align="right" style="width: 159%"><tr align="center"> <td align="right" style="width: 110px; height: 26px;">Exec Name if Involved:</td><td align="left" style="height: 26px"><SELECT id="Exec_Name" name="Exec_Name"><option selected value="Exec Not Involved">Please Select... </option><option value='Tom'>Tom</option><option value='Elle'>Elle</option><option value='Bob'>Bob</option><option value='Andy'>Andy</option><option value='Clarke'>Clarke</option><option value='Rick'>Rick</option><option value='Sam'>Sam</option></select></td></tr></table></li><li id='submitbuttomli' style="width: 580px"><table border="0" align="right" style="width: 156%"><tr align="right"><td align="left" style="width: 110px; height: 30px;"></td><td align="left" style="height: 30px"> <input name="AvailbtnSubmit" value="Submit Request" onclick="vb script: call Availcheckform()" type="button"></td></tr></table></li></ul></div><!--Other Div Element--><div id='No' class='topbar' style="left: 193px; top: 490px"><script type="text/vbscript">function Othercheckform()dim intError, strErrorintError = 0strError = "Please ensure you have completed all information before submitting this form." & vbcrlf & vbcrlfif len(document.all.Requested_By.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Your Full Name" & vbcrlfElsedocument.all.MainReqBy.value = document.all.Requested_By.valuedocument.all.MainCase_Sheet.value = document.all.Case_Sheet.valueend ifif len(document.all.Store_Name.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Store Name" & vbcrlfElsedocument.all.MainStoreName.value = document.all.Store_Name.valuedocument.all.MainStore_Name.value = document.all.Store_Name.valueend ifif len(document.all.Store_No.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Store Number" & vbcrlfElsedocument.all.MainStoreNo.value = document.all.Store_No.valuedocument.all.MainStore_No.value = document.all.Store_No.valueend ifif len(document.all.Arena_No.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Arena Number" & vbcrlfElsedocument.all.MainArenaNo.value = document.all.Arena_No.valuedocument.all.MainArena_No.value = document.all.Arena_No.valueend ifif len(document.all.Case_No.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Case Number" & vbcrlfElsedocument.all.MainCaseNo.value = document.all.Case_No.valuedocument.all.MainCase_No.value = document.all.Case_No.valueend ifif len(document.all.Incident_Value.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Incident Value" & vbcrlfElsedocument.all.MainIncidentValue.value = document.all.Incident_Value.valuedocument.all.MainIncident_Value.value = document.all.Incident_Value.valueend ifif len(document.all.Total_Recovered.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Recovered Value" & vbcrlfElsedocument.all.MainTotalRecovered.value = document.all.Total_Recovered.valuedocument.all.MainTotal_Recovered.value = document.all.Total_Recovered.valueend ifif len(document.all.Case_Status.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Case Status" & vbcrlfElsedocument.all.MainCase_Status.value = document.all.Case_Status.valuedocument.all.MainCase_Status.value = document.all.Case_Status.valueend ifif len(document.all.Action_Taken.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Action Taken" & vbcrlfElsedocument.all.MainAction_Taken.value = document.all.Action_Taken.valuedocument.all.MainAction_Taken.value = document.all.Action_Taken.valueend ifif len(document.all.OtherDetailed_Request.value) = 0 thenintError = intError + 1strError = strError & intError & ". Required > Please provide us with some detail about your request" & vbcrlfElsedocument.all.MainOtherInfo.value = document.all.OtherDetailed_Request.valueend ifif intError > 0 thenmsgbox strError, vbokonly, "Form Incomplete..."elsedocument.all.recipient.value = "thomas.horner@asda.co.uk, ian.mcdonald@asda.co.uk, john.flood@asda.co.uk, julie.barff@asda.co.uk"document.all.OtherbtnSubmit.disabled = truedocument.all.OtherbtnSubmit.value = "Please Wait While We Submit Your Information"document.all.feed_form.submit()end ifend function</script><ul id='mylist' style="width: 582px"><li id='OtherDetailsli' style="width: 580px"><table border="0" align="left" style="width: 159%"><tr align="center"> <td align="right" style="width: 110px">Other Details:</td><td align="left"><textarea rows="5" name="OtherDetailed_Request" style="width: 350px"></textarea></td></tr></table></li><li id='submitbuttomli' style="width: 580px"><table border="0" align="right" style="width: 156%"><tr align="right"><td align="left" style="width: 110px; height: 30px;"></td><td align="left" style="height: 30px"> <input name="OtherbtnSubmit" value="Submit Request" onclick="vb script: call Othercheckform()" type="button"></td></tr></table></li></ul></div></div><!--------------------------MasterForm--------------------------><Form action="http://wirecontent.wal-mart.com/cgi-bin/formmail.pl" method="post" id="feed_form"><Input name="recipient" id="recipient" value="" type="hidden"><Input name="subject" value="Investigation Form" type="hidden"><Input name="E-mail" value="communication@asda.co.uk" type="hidden"><Input name="ATTENTION" value="________Please do not reply directly to this mail." type="hidden"><input type="hidden" name="redirect" value="http://mywirecontent.wal-mart.com/en_GB/gbwire/forms/redirect/thanks.htm" /><Input name="MainReqBy" id="MainReqBy" value="" type="hidden"><input name="MainStoreName" id="MainStore_Name" value="" type="hidden"><input name="MainStoreNo" id="MainStore_No" value="" type="hidden"><input name="MainArenaNo" id="MainArena_No" value="" type="hidden"><input name="MainCaseNo" id="MainCase_No" value="" type="hidden"><input name="MainIncidentValue" id="MainIncident_Value" value="" type="hidden"><input name="MainTotalRecovered" id="MainTotal_Recovered" value="" type="hidden"><Input name="MainCase_Status" id="MainCase_Status" value="" type="hidden"><Input name="MainAction_Taken" id="MainAction_Taken" value="" type="hidden"><Input name="MainCase_Sheet" id="MainCase_Sheet" value="" type="hidden"><Input name="MainOtherInfo" id="MainOtherInfo" value="" type="hidden"><Input name="MainTypeIncident" id="MainType_Incident" value="" type="hidden"><Input name="MainExec_Name" id="MainExec_Name" value="" type="hidden"></Form><iframe style="visibility:hidden; position:absolute;top:150px;right:150px;" src ='http://ukweb01.homeoffice.uk.wal-mart.com/ccuksitefiles/PrcssImpAvail/countprocess.asp'></iframe></body> Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.