var thisUrl=document.URL.toString(), start=1+thisUrl.indexOf('?'), qs=thisUrl.substring(start,thisUrl.length); // Capture the QueryString
if (start > 0) // If there is a QS then...
 { var sets=qs.split('&'), nsets=sets.length; // sets is an array of strings in the format var=value
   for(i=0;i<nsets;i++) // for each pair...
    { pair=sets[i].toString().split('=');    // splice it...
      eval("var "+pair[0]+"='"+pair[1]+"';");  // and eval it.
    }
 }