473,732 Members | 2,204 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Refreshing one iframe from another?

Hi there..

I have a file that contains three iframes, when one of the iframes is
updated (via <form target ...> then it must 'refresh/reload' the originating
iframe, ie. the iframe that sent the form action.

I've looked around, but I haven't managed to find a method yet, that does
not utilitize some MS only method. So how do I do it, and maintaining W3C
compatibility?

--
I doubt, therefore I might be.
Jul 23 '05 #1
2 8610


Kim Noer wrote:

I have a file that contains three iframes, when one of the iframes is
updated (via <form target ...> then it must 'refresh/reload' the originating
iframe, ie. the iframe that sent the form action.

I've looked around, but I haven't managed to find a method yet, that does
not utilitize some MS only method. So how do I do it, and maintaining W3C
compatibility?


Not W3C but if you use
<iframe name="iframe1" ...
and
<iframe name="iframe2"
then you can script
if (parent.frames. iframe2) {
parent.frames.i frame2.location .reload();
}
that is more compatible with existing browsers than relying on W3C DOM
stuff where you need
<iframe id="iframe1" ...
and
<iframe id="iframe2"
with script
if (parent.documen t.getElementByI d) {
var iframe2 = parent.document .getElementById ('iframe2');
if (iframe2 && iframe2.default View) {
iframe2.default View.location.r eload();
}
}
--

Martin Honnen
http://JavaScript.FAQTs.com/
Jul 23 '05 #2
"Martin Honnen" <ma*******@yaho o.de> wrote in message
news:41******** *************** @newsread2.arco r-online.net
Not W3C but if you use (...)
that is more compatible with existing browsers than relying on W3C DOM


Thanks a bunch, this one worked without any problem (both in IE and
Firefox).

--
I doubt, therefore I might be.
Jul 23 '05 #3

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

Similar topics

1
22931
by: bb | last post by:
I am trying to force an iframe to refresh from the server using the following javascript: document.frames("frm").document.location.reload(true) The iframe html is: <iframe id="frm" name="frm" src="https://ourdomain/..." width="0" height="0" border="0"></iframe> The parent and iframe are both hosted in the same domain, and are both
1
1753
by: viktor9990 | last post by:
I have a page called CustomerSlides.aspx which contains an iframe(with the source Lookupage.aspx). The iframe page will look continuously in the database to see if a value has changed: if it is true it will run a java script dynamically to update the parent page CustomerSlides.aspx.cs. The value in the Database is changed from another aspx page så all the changes made in this page will be updated in CustomerSlides.aspx. I used the code...
1
1803
by: viktor9990 | last post by:
I have a page called CustomerSlides.aspx which contains an iframe(with the source Lookupage.aspx). The iframe page will look continuously in the database to see if a value has changed: if it is true it will run a java script dynamically to update the parent page CustomerSlides.aspx.cs. The value in the Database is changed from another aspx page så all the changes made in this page will be updated in CustomerSlides.aspx. I used the code...
3
2481
by: Dan | last post by:
Hi, I am trying to refresh the cookie to make sure the timeout is reset by simply calling a blank page on my site. I am doing this because I have an external site hosted in my web that isn't sharing the auth mechanism. I can test this easily by simply having a hidden iframe and use a javascript call to refresh my sites blank page every time the external site loads a page and this does work fine, the cookie is refreshed as expected if...
3
5395
polymorphic
by: polymorphic | last post by:
I have succeeded in embedding PDF files in a dynamic iframe. The problem is that I need the PDF to cache. If the PDF remains the same from page load to page load then the pdf is somehow cached with the html page. But if I try to navigate to another pdf in the IFRAME then no caching occurs. Is the problem in the IFRAME reloading instead of just refreshing the pdf? <SCRIPT type="text/javascript"> var pageNo; var nav; var iframe; var...
6
5143
by: bnashenas1984 | last post by:
Here you can see the script I found in google to refresh a page without hearing any click sound which is usual to hear when a link is clicked or a page is refreshed. <script type="text/javascript" > window.onload = doLoad; function doLoad() { setTimeout( "refresh()", 5*1000 );
0
2064
by: Bali | last post by:
Default.aspx is the starting page containing a control(ascx) which has asp:button control on it. On the button click event it has to open a new page as a modal control. Since refreshing a page in a dialog box ended up opening up a new browser window with the aspx page, I read on a forum that I should use the iframe control and since I have to open a bunch of pages as diaogboxes, I created a general page(Container.aspx) which has an...
1
9411
by: Bali | last post by:
Default.aspx is the starting page containing a control(ascx) which has asp:button control on it. On the button click event it has to open a new page as a modal control. Since refreshing a page in a dialog box ended up opening up a new browser window with the aspx page, I read on a forum that I should use the iframe control and since I have to open a bunch of pages as diaogboxes, I created a general page(Container.aspx) which has an...
1
2952
by: bnashenas1984 | last post by:
Hi everyone I'v seen several websites doing what I'm asking now but I don't know how they do it. Lets say we have an E-commerce website that has a shopping cart inside an IFrame which shows what products have been added. Users should be able to add comments for each product inside the shopping cart (in the Iframe) . When the user clicks on the product a new popup window opens which allows him to add the comment and then save. But...
0
8946
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9447
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9235
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9181
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8186
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6735
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
1
3261
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2721
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2180
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.