As our site is currently hosted with another company they are charging huge amounts for any changes I cannot do the obvious option which would be to upgrade. Until we get out site back (hosted inhouse) I need a work around.
I am working in umbraco 4.7 and contour 1.something. I have a form with a tick box for pay now what I want is when the paynow checkbox is checked a link to paypal becomes visable. So far I have this which works but it shows the alert before the page is loaded how do I get it to
1. work after the page is loaded and 2. show a link rather than an alert. I know it's more a javascript question but I'm hoping someone can help.
Thanks in advance
Natasha
if($(".contourField checkbox paynow checkbox alternating").attr("checked")==true) { alert("can you do this after"); } else { alert("this doesn't work"); } }
Using javascript to check if a box is checked
Hi there
As our site is currently hosted with another company they are charging huge amounts for any changes I cannot do the obvious option which would be to upgrade. Until we get out site back (hosted inhouse) I need a work around.
I am working in umbraco 4.7 and contour 1.something. I have a form with a tick box for pay now what I want is when the paynow checkbox is checked a link to paypal becomes visable. So far I have this which works but it shows the alert before the page is loaded how do I get it to
1. work after the page is loaded and 2. show a link rather than an alert. I know it's more a javascript question but I'm hoping someone can help.
Thanks in advance
Natasha
Code update still have the first problem but have sorted the second:
<script type="text/javascript">
window.onload = function() {
if($(".contourField checkbox paynow checkbox alternating").attr("checked")==true)
{
window.location = '/paypal';
}
else
{
window.location = '#'
}
}
</script>
is working on a reply...