how to see variables from javascript in php code example
Example: javascript access php variable
//passing PHP variable to JavaScript
var myJSVar = <?php echo json_encode($myPHPVar); ?>;
//passing PHP variable to JavaScript
var myJSVar = <?php echo json_encode($myPHPVar); ?>;