Page 1 of 1

javascript error in PHP page

Posted: Tue Mar 16, 2010 11:06 pm
by kevinwinters
Hi,
I have to develop on a windows machine (wamp), then upload to a Linux machine, on one page I have a javascript to handle an onchange event. In Windows, it works fine - but once I upload to a Linux machine, I get an error at the if statement

Could anyone give me an idea about what is wrong/

Code: Select all

 
<script language="Javascript" type="text/javascript"> 
    function ReactToChange(){
    if (document.getElementById("sales_status").value == "sold" && document.getElementById("istatus").value == "available" )
    {       document.getElementById("soldselect").checked = true    }
    else
    {       document.getElementById("soldselect").checked = false   }
    }
</script>
 

Re: javascript error in PHP page

Posted: Wed Mar 17, 2010 2:16 am
by cpetercarter
Don't you need semicolons at the end of the statements on lines 5 and 7?

Re: javascript error in PHP page

Posted: Wed Mar 17, 2010 3:08 pm
by infolock
what exactly is the error message?