Hey Guys,
I'm trying to make a popup. Let me rephrase, not the type of popup that we all have cursed upon! But the same concept. I have a "control panel" type web application that i have developed. It is all completely dynamic. Each application has its own index.php file. My problem is, one of my applications i need has to open in a new window since its an external site. My problem is the way i have it setup dynamically in php i MUST have that inital index.php file. So what i have tried is to put in that index file just some javascript that opens a new window. Of course both IE and FF's popup blocker kick in. I need to find away around this. Does anyone have any ideas? So far i'd tried a window.open.... also tried creating a link with a target and id and then using click(); to deploy it. And i even tried creating a fake form with a target and an id and submiting it with javascript. Everything gets blocked.
So what i have tried is to put in that index file just some javascript that opens a new window. Of course both IE and FF's popup blocker kick in. I need to find away around this. Does anyone have any ideas? So far i'd tried a window.open.... also tried creating a link with a target and id and then using click(); to deploy it. And i even tried creating a fake form with a target and an id and submiting it with javascript. Everything gets blocked.
Thanks in advance,
Jamie
Forget it. Pop-up blockers are designed to stop exactly what you are trying to do. If they could be circumvented every spammer in the universe would have done it already.
Personally, I agree with rubenbuhr. I think it is the best and easiest solution to this problem.
To learn more about IFrames, you should google search IFrames and how to implement one. I found this website which give a quick overview of IFrames are used within a page.
I could think of other solutions to this problem. Such as using Ajax to populate contents needed from the other server. (I know, there is a security thing which does not allow you to connect to another server...but I have a work around for that). But they all rely on JavaScript and I think you should stick to using an IFrame.
hi ess, thank you for the responce. I know what an iframe is and i've used them a good bit. I just don't understand how that will help me open a new window?
Oh dear! You have not read what Stephen Chapman says:-
"I can't guarantee that your popup will appear if you code it this way. All I can guarantee is that your popup will have a better chance of making it past the blockers if coded like this as it makes it more obvious to the popup blockers that the popup window has actually been requested by the person viewing the page and is not being generated automatically."
This does not enable unrequested or automatic pop-ups to get through. It merely helps if the pop-up has actually been requested and the browser does not recognise this.