Staredit Network

Staredit Network -> Computers and Technical -> Javascript and PHP
Report, edit, etc...Posted by Pie_Sniper on 2006-01-13 at 21:02:15
I obtain a string in Javascript, Info, and I want to load that variable into a PHP variable, $Write. I've been Googling for a while now, and I can't find anything that works. How do I do this? I'm using PHP4.
Report, edit, etc...Posted by Doodle77(MM) on 2006-01-13 at 22:09:43
you use a get variable, that part that says
?showtopic=25623
so you have something like
CODE

<script language="javascript">
function sendtoPHP(thisvar) {
window.location = "yoursite.com/thatphpfile.php?write=" + thisvar;
}
</script>

and then the PHP
CODE

<?php
$Write = $_GET['write'];
// then whatever you were going to put.
?>
Next Page (1)