Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating a Child Window

Status
Not open for further replies.

lakeside12

Programmer
Apr 20, 2009
43
CA
Hello

Is it possible to create a child window that would not be affected by a popup blocker, if I can create a smaller child window on top on the parent window that i can populate with info I would be really happy. Is this possible?

I saw one last week, it was definitely a child window inside the parent window, so you could move it, resize it, but it could not go outside the bounds of the parent window.

Any help would be appreciated
Kind regards
 
From your description, it sounds very much like it was not actually a real window because:

1) A real window may have been scuppered by the popup blocker, and

2) A real window would have been able to move outside the boundaries of its parent.

My guess is that it was either an IFRAME or DIV element made movable with some JS library or other.

To answer your question, if you want to do something similar without a popup blocker wrecking your chances, then you should have no problem creating a similar element (IFRAME or DIV) and loading a page into it.

Hope this helps,
Dan



Coedit Limited - Delivering standards compliant, accessible web solutions

Dan's Page [blue]@[/blue] Code Couch:
Code Couch Snippets & Info:
The Out Atheism Campaign
 
Is it possible to create a child window that would not be affected by a popup blocker

Hopefully, there isn't. It would defeat the purpose of pop-up blockers which is to prevent unwanted pop-ups. I'd hate going to a website, only to be barraged with un-blockable pop-ups.

With that said, I agree with Dan. Its likely a DIV being manipulated by Javascript to look and act like a child window.

Like this for instance:

----------------------------------
Phil AKA Vacunita
----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.

Behind the Web, Tips and Tricks for Web Development.
 
Hi Thanks for your responses which I really appreciate, and I agree with you about popups,I remember the 90's

I will use the iFrame

Code:
<iframe name="FRAME1" src="contentpage.htm" width="100" height="280" frameborder="1" scrolling="no" allowautotransparency=true></iframe>

Question, is it possible to change the iframe source from one html file to another with something like this
Code:
document.getElementById('FRAME1').src='resultpage.htm';

Sorry, I am not lame, I could try this myself, i will not be infront of this computer project until 3pm

Kind regards
 
Don't believe so; I think you need to access the frame through the frames collection using its name and not its ID to be able to alter its src that way so:

document.frames['FRAME1name'].src="resultpage.htm";

----------------------------------
Phil AKA Vacunita
----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.

Behind the Web, Tips and Tricks for Web Development.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top