I just think this is useful for people having this problem:
I had this code:
<html>
<head>
<link rel="stylesheet" href="example.css" type="text/css"/>
<title>CSS TESTS</title>
<script language="text/javascript">
var move = 0;
</script>
</head>
<body>
<input type="text" id="shape" onchange="alert(move);"/>
</body>
</html>
But I couldn't get the alert to work. I would get the Uncaught ReferenceError: move is not defined.