function popupURL(url) {
   mywindow = window.open (url, "mywindow", "scrollbars=1,resizable=1,width=500,height=700"); 
}

function getParam(name) {
  var regexS = "[\\?&]"+name+"=([^&#]*)";
  var regex = new RegExp( regexS );
  var tmpURL = window.location.href;
  var results = regex.exec( tmpURL );
  if( results == null )
    return "";
  else
    return results[1];
}