I have the following problem:
I'm using JavaScript to set a input
type hidden
in a modal window. Now I need to assign the value that was filled in this field to a PHP variable. I'm not using any form, just the field alone. I tried the following code that does not work:
<?php
$x = "<script>document.write(bookId)</script>";
echo $x;
?>
How do I get the value of this field and assign it to the variable?