function OpenPopup(theURL,popW, popH, scroll, el, e, name) { 
   now = new Date();
   //theURL = theURL.replace(/™/,'%99'); //this was causing errors in IE sometimes
   theURL = theURL.replace(/\u2122/,'%99');
   var winleft = (screen.width - popW) / 2;
   var winUp = (screen.height - popH) / 2;
   var theName= name ? name : "tmp"+ now.valueOf();
   winProp = 'width='+popW+',height='+popH+',left='+winleft+',top='+winUp+',scrollbars='+scroll+',resizable'
   Win = window.open(theURL, theName, winProp)
   if (parseInt(navigator.appVersion) >= 4) { Win.window.focus(); }
}

