Access a javascript function value within PHP?
<p>Can I access the value of a javascript function from outside the function 
like if I had a function</p>

<pre><code>&lt;script&gt;
function test_tree(opt)
{
    val = opt;
}
&lt;/script&gt;
</code></pre>

<p>Can I access the <code>val</code> value from outside the <code>test_tree</code> function or is there a way to access it from PHP code?</p>

<p>I need to be able to access a value from the javascript code in PHP code.</p>
