Hi i would to make a counter that will increase by one every time someone goes on my page
Now here is my code:
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>counter</title>
</head>
<script language="JavaScript" type="text/javascript">
var number=0
function add()
{
number++;
document.f.counter.value=number;
}
</script>
<body onload="add()">
<form name="f">
<input type="text" name="counter" value="">
</form>
</body>
</html>
But the value will alway be 1, even if i reload. Is there anyway to make the var number keep the new number?
__________________
forum-------> Please login or register to view this content. Registration is FREE, for people who wants to have a good time ;)
website------> Please login or register to view this content. Registration is FREE (might be in construction :D)
Hope you have a great time and that my post is helpfull ;)
|