function openNewWindow(URLtoOpen, windowName, windowFeatures, w, h) {
 
    x = (screen.availWidth-w)/2;
    y = (screen.availHeight-h)/2;
 
    windowFeatures = ('width='+w+',height='+h+',left='+x+',top='+y+'') + windowFeatures;
	newWindow=window.open(URLtoOpen, windowName, windowFeatures); 
}

