startbar
03-26-2006, 04:09 PM
<form action="https://secure.nochex.com" method=post name=quickpay onsubmit="return submitForm();">
<title>XXXXXXXX</title>
<div style="padding-top:10px;padding-bottom:5px;padding-left:2px;padding-right:2px;">
<script type="text/javascript">
function changetext(whichcontent){
if (document.all||document.getElementById){
cross_el=document.getElementById? document.getElementById("descriptions"):document.all.descriptions
cross_el.innerHTML=whichcontent
}
else if (document.layers){
document.d1.document.d2.document.write(whichcontent)
document.d1.document.d2.document.close()
}
}
function update(){
var f1 = document.quickpay;
var amt = 0
if (f1.plug.checked){
amt += 58.75;
changetext("Total £: <input type='text' name='amount' style='background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #FFFFFF;'>");
}else{
changetext("Total £: <input type='text' name='amount' style='background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #FFFFFF;'>");
}
f1.amount.value=amt;
}
</script>
</head>
<body bgcolor="#990000" onload="changetext('<b>Total £: <input type='text' name='amount' id='amount' style='background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #FFFFFF;'></b>')">
<input name="email" size="35" type="hidden" value="xxx" style="background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #FFFFFF;"><img src="/makeapayment.jpg" border="0"><br>I would like to pay for a Plug Point - £50 + vat <input type="checkbox" name="plug" onclick="update()"><br>
<br>
My stand number is: <input type="text" size="10" id="description" name="description" style="background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #CCCCCC;"><br><br>
<ilayer id="d1" width="35" height="15" visibility="hide">
<layer id="d3" width="35" height="15">
<div id="descriptions" align="left">
</div>
</layer>
</ilayer>
<br>
<input name="cancelurl" type="hidden" value="">
<input type="submit" value="Continue to Payment" style="background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #990000;" name=submit1>
</form>
Can someone please add some code to this for me! I would really appriciate it. Need the tickbox <input type="checkbox" name="plug" onclick="update()"> and the stand text field <input type="text" size="10" id="description" name="description" style="background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #CCCCCC;"> to be required fields. Maybe if possible could you do it so that the submit button is disabled until the box is ticked and the field typed into.
Many thanks in advance
<title>XXXXXXXX</title>
<div style="padding-top:10px;padding-bottom:5px;padding-left:2px;padding-right:2px;">
<script type="text/javascript">
function changetext(whichcontent){
if (document.all||document.getElementById){
cross_el=document.getElementById? document.getElementById("descriptions"):document.all.descriptions
cross_el.innerHTML=whichcontent
}
else if (document.layers){
document.d1.document.d2.document.write(whichcontent)
document.d1.document.d2.document.close()
}
}
function update(){
var f1 = document.quickpay;
var amt = 0
if (f1.plug.checked){
amt += 58.75;
changetext("Total £: <input type='text' name='amount' style='background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #FFFFFF;'>");
}else{
changetext("Total £: <input type='text' name='amount' style='background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #FFFFFF;'>");
}
f1.amount.value=amt;
}
</script>
</head>
<body bgcolor="#990000" onload="changetext('<b>Total £: <input type='text' name='amount' id='amount' style='background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #FFFFFF;'></b>')">
<input name="email" size="35" type="hidden" value="xxx" style="background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #FFFFFF;"><img src="/makeapayment.jpg" border="0"><br>I would like to pay for a Plug Point - £50 + vat <input type="checkbox" name="plug" onclick="update()"><br>
<br>
My stand number is: <input type="text" size="10" id="description" name="description" style="background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #CCCCCC;"><br><br>
<ilayer id="d1" width="35" height="15" visibility="hide">
<layer id="d3" width="35" height="15">
<div id="descriptions" align="left">
</div>
</layer>
</ilayer>
<br>
<input name="cancelurl" type="hidden" value="">
<input type="submit" value="Continue to Payment" style="background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #990000;" name=submit1>
</form>
Can someone please add some code to this for me! I would really appriciate it. Need the tickbox <input type="checkbox" name="plug" onclick="update()"> and the stand text field <input type="text" size="10" id="description" name="description" style="background-color: #FFFFFF; font-family: verdana; font-size: 8pt; color: #990000; font-weight: none; border: 1px solid #CCCCCC;"> to be required fields. Maybe if possible could you do it so that the submit button is disabled until the box is ticked and the field typed into.
Many thanks in advance