Forum Moderators: open
I have managed to pass the php variable to javascript as below
<script language=JavaScript>
var a = <?PHP echo "$number";?>
a+=1;
document.write(a) //will produce 6
</script>
but i need this to work the other way round with the button click adding 1 to $number. Do i need to be looking into ajax?
Any help much appreciated
Yes. Here's a good place to start: [news.php.net...]