473,406 Members | 2,847 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

PLEASE How to break out of an iframe?

On a page I'm offering file download links which are each targeted to an
tiny 1-pixel X 1-pixel iframe on the same page. (If you care why, see
below.) Under certain conditions, I want to popup a window which is NOT
constrained within the iframe to which its creator page is targeted. But
since the download page is being targeted to the tiny iframe on the
application page, any popups or alerts I've tried creating from the download
page's code do not appear, presumably because they're being created inside
the "invisible" iframe.

Is there any method for asserting on a page that a window or alert should
NOT appear in the iframe to which the page was supposed to send its output?
I'm developing in ASP.NET, so can modify page HTML and Javascript just
before the page is sent to the browser.

The reason I'm targeting links to the tiny iframe is that when users select
a file for download, the standard Windows open / save / cancel dialog pops
up over the page they clicked rather than first opening a new "file
download" page. When download is complete and the dialog disappears the
original page remains ready for another user selection. The giant download
site tucows.com uses this technique. However if there's another way to get
this functionality I'm all ears!

1. User selects file for download on application page.

2. If no errors, standard Windows dialog pops up over application & download
proceeds without changing application page. When download completes, dialog
disappears and application page remains unchanged ready for further use.

3. If error, window or alert pops up over application. When closed,
application page remains unchanged ready for further use.

Thanks for ANY ideas.
Jul 20 '05 #1
1 5640
In article <7nSkb.98755$mf.65231
@twister01.bloor.is.net.cable.rogers.com>, no****@nospam.com enlightened
us with...
On a page I'm offering file download links which are each targeted to an
tiny 1-pixel X 1-pixel iframe on the same page. (If you care why, see
below.) Under certain conditions, I want to popup a window which is NOT
constrained within the iframe to which its creator page is targeted. But
since the download page is being targeted to the tiny iframe on the
application page, any popups or alerts I've tried creating from the download
page's code do not appear, presumably because they're being created inside
the "invisible" iframe.


Don't know if this works, since I am a bit pressed for time and don't
have time to test it.
Give it a shot...

if (whatever error you want to catch)
{
opener.alert("error");
}

It may depend on domains and permissions and such, but it sounds like
all the pages are yours, so...

-------------------------------------------------
~kaeli~
Jesus saves, Allah protects, and Cthulhu
thinks you'd make a nice sandwich.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace
-------------------------------------------------
Jul 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: David Van D | last post by:
Hi there, A few weeks until I begin my journey towards a degree in Computer Science at Canterbury University in New Zealand, Anyway the course tutors are going to be teaching us JAVA wth bluej...
0
by: sfrvn | last post by:
I found the following post while researching this subject: " Refresh Parent from iframe Page_Load " This is EXACTLY what I need to do. However, my lack of experience and C# knowledge simply do...
4
by: alxasa | last post by:
Hi, this is my present configuration <FRAMESET ID="MAIN_BODY" FRAMESPACING="0" ROWS="100%,*" FRAMEBORDER="0"> <FRAME NAME="frameA" SRC="./contentA.htm"> <FRAME NAME="frameB"...
3
by: PCgeek | last post by:
sorry moved this over to javascript forum, didn't mean to post 2x! Hi guys, I'm trying to put the finishing touches on my website and could really use some help on this particular issue. My page...
1
by: Bob | last post by:
Hi, Hope you can help me with this one. I'm at my wits end. I'm trying to create an intelligent edit-box like the excellent "Customer" one at the URL: ...
2
by: kwenterprise | last post by:
Hello All, I am normally great at figuring out ways around iframe issues that frustrate us all. I am using javasript to try and break an iframe that I have a banner rotator embedded in but it...
2
by: cybervigilante | last post by:
I have a table inside an iframe that has paypal buttons in table cells. Each button is a Form. (The table has to be in an iframe to protect it from a containing CMS, which buggers the forms...
0
by: magicofureyes | last post by:
Hello Guys im a just a new user and i dnt knw much abt Xml i want to upload a new template in Blogger so got some free coding but when i save this code in Blogger template it say '''' Your...
1
PepsiHack
by: PepsiHack | last post by:
Ok i am developing a site on a server that only allows HTML and some Java Script - The Server displays my pages in its own layout. I tried to set up hosting somewhere else, however the organization...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.