Fetching all (javascript) global variables in a page
<p>Is there a way to retriev the name/value of all global variables on a page?</p>

<p>I would like to write a javascript function to do the following:</p>

<ol>
<li>Find all global variables prefixed with 'xxx_' and stick them in an array (for e.g.)</li>
<li>build a query string using the name value pairs as follows:
xxx_glob_var1=value1&amp;xxx_glob_var2=value2  etc</li>
</ol>

<p>Could anyone offer some snippets to show how I may do this?</p>
