Jump to content

How to open pop up window within a popup window


garrisonian14

Recommended Posts

I am working in php, i open a pop up window using javascript function when someone clicks on a link. Now there is a link in this pop up window, when user clicks on this link another pop up window must be opened. i am unable to do this. Can anybody please provide urgent help fo this.

 

Thanx in anticipation

 

Regards,

 

Ali.

Link to comment
Share on other sites

an easy way to do this is create an external javascript and put this in it:

 


function myWin(url,puw,puh)
{
window.open(url,"thisWin","resizable=no,scrollbars=no,toolbar=no,menubar=no,location=no,status=no,directories=no,fullscreen=no,dependent=no,sreenX=0,screenY=0,top=0,left=0,width="+puw+",height="+puh+"");
}

 

name the js file what ever you want it to be named. for this example, I will name it "popWindows.js".

 

now then, were ever you want a pop-up window to be; you will do this:

 


<!-- This Loads Your External JS File -->
<script type="text/javascript" src="popWindows.js"></script>

<!-- 
**************************************************************
The myWin Functions Is Set-Up Like This 
**************************************************************

myWin(url,puw,puh)

url = the web address/url of your pop-up
puw = the width of your pop-up window
puh = the height of your pop-up window

-->

<a href="#" onclick="myWin('page1.php','400','325')">Open Window</a>

 

and this should solve you multiplet pop-up issue.

 

Link to comment
Share on other sites

an easy way to do this is create an external javascript and put this in it:

 


function myWin(url,puw,puh)
{
window.open(url,"thisWin","resizable=no,scrollbars=no,toolbar=no,menubar=no,location=no,status=no,directories=no,fullscreen=no,dependent=no,sreenX=0,screenY=0,top=0,left=0,width="+puw+",height="+puh+"");
}

 

name the js file what ever you want it to be named. for this example, I will name it "popWindows.js".

 

now then, were ever you want a pop-up window to be; you will do this:

 


<!-- This Loads Your External JS File -->
<script type="text/javascript" src="popWindows.js"></script>

<!-- 
**************************************************************
The myWin Functions Is Set-Up Like This 
**************************************************************

myWin(url,puw,puh)

url = the web address/url of your pop-up
puw = the width of your pop-up window
puh = the height of your pop-up window

-->

<a href="#" onclick="myWin('page1.php','400','325')">Open Window</a>

 

 

 

and this should solve you multiplet pop-up issue.

 

 

Thanx for your help, i have done it

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.