Jump to content

popup behavior with php


Curator

Recommended Posts

I have my index.php page that has a popup called getinfo.php.  It is small 630 x 330 popup that has two listboxes where I select the course and authors.

 

It then sends me to viewquestions.php where I can view all the questions belonging to that course created by those authors.

 

The problem is viewquestions.php is displayed in the same window as was getinfo.php ( 630 x 330 )

 

I would like viewquestion displayed in its own separate window but much larger like 800 x 600.

 

The popup code expects the following:

 

function popUp(URL,width,height,resize, statusbar) 

 

My getinfo.php popup page has the following button to open the viewquestions page but it is not working as needed.

 

."<input type=\"submit\" onClick=\"j@v@scr!pt:popUp('".append_sid('viewquestions.php')."', 800,600,1,0)\" value=\"Submit!\">"

 

Any help will be greatly appreciated.

 

I have tried to use onClick=window.location but that didn't work either.

 

Here is what the javascript looks like.

 

 

function popUp(URL,width,height,resize, statusbar) {

day = new Date();
id = day.getTime();

eval("page" + id + " = window.open(URL, '" + id + "','toolbar=0,scrollbars=1,location=0,left=0,top=0, statusbar="+statusbar+",menubar=0,resizable="+resize+",width="+width+",height="+height+"');");

}

Link to comment
https://forums.phpfreaks.com/topic/73678-popup-behavior-with-php/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.