/*-----------------------------------------------------------------------------------

 * © Ganz - This code is exclusively the property of Ganz and all 
 * rights therein, including without limitation copyrights and trade
 * secrets, are reserved by Ganz.  Any reproduction, disclosure,
 * distribution or unauthorized use is strictly prohibited.
  
 javaScript document: gup.js
 
 parses query string of URL rather nicely
  
 -----------------------------------------------------------------------------------*/
function gup(url, name )
{
  if(name){
	  name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]");
	  var regexS = "[\\?&]"+name+"=([^&#]*)";
	  var regex = new RegExp( regexS );
	  var results = regex.exec( url );
	  if( results == null )
    	return "";
	  else
    	return results[1];
  }
  else{return null;}
}
