function wf_open_window(url, name, width, height, position, features) { if (position == 'right') { newScreenX = screen.width - width; newScreenY = 0; } else { if (position == 'center') { newScreenX = (screen.width / 2) - (width / 2); newScreenY = 0; } else { newScreenX = 1; newScreenY = 0; } } name = window.open(url, '', 'width='+width+',height='+height+',' + 'screenX='+newScreenX+',left='+newScreenX+',screenY='+newScreenY+',' + 'top='+newScreenY+','+features); } EOF; return $output; } ?>