Hello,

I'm trying to parse the querystring but not having much luck, tried several methods to no avail. Can anyone see what I'm doing wrong? Here is the querystring I'm trying to parse.

file:///C:/Program%20Files%20(x86)/Apache%20Group/Apache2/cgi-bin/popup.html?TxtName=Rick&Organization=GSD+AMS&Organization1=&Sponser=Mike+Eberhardt&Sponser1=&reason= IDSS+Sales+Training&reason1=&Country=840

and this is the page I call:

<Code>
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript">
function getValue()
{
// alert("hello");
// First, we load the URL into a variable
// write.document("Made it in");
//var url = window.location.href;
//write.document(url);
var query = (window.location.search || '?').substr(1),
map = {};
query.replace(/([^&=]+)=?([^&]*)(?:&+|$)/g, function(match, key, value) {
(map[key] = map[key] || []).push(value);
});
write.document(map);
return map;


}
</script>
<Center>

<body>
<script>
window.onload=getValue();
</script>
<h1>Terms and Conditions</h1>
<p>Bags are subject to search upon entrance and exit.</p>
<p>Photo ID is Required.</p>
<p>You must be escorted at all times.</p>
<FORM ACTION="http://localhost:80/cgi-bin/sqlconfig.pl" METHOD="POST">
<td><INPUT STYLE="font-size:20px" TYPE="SUBMIT" VALUE="I accept" align="center" ></td>
</head>
</body>
</html>
</code>


I'm trying to get:
name
organization
organization1
sponser
sponser1
reason
reason1
country

off the query string.

Thanks
Rick