I have a side navigation bar and when you click the links it submits a form. The forms action opens another page ( target _blank). My problem is I have to open a popup window before this blank page opens and keep it open long enough for the user to read it or atleast see it first and close it if they wish. I created a function that opens the popup on the onclick event of the link. Looks like this:
<li><a href="JavaScript:document.quoteform.submit()" onclick="popUp('ag_popup.html')">Submit a Deal</a></li>
and my function looks like this:
function popUp(url)
{
leftPos = 0
topPos = 0
if (screen) {
leftPos = (screen.width / 2) - 150
topPos = (screen.height / 2) - 250
}
newwindow=window.open(url,'name','height=300,width=500,left='+leftPos+',top='+topPos);
if (window.focus) {newwindow.focus()}
return false;}
Does anyone know if I can just keep my popup open and focused without my new blank page opening up infront of it?
Cheers