473,788 Members | 2,652 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Javascript & iframes

I want to load a javascript file on a root page with various iframes,
then call the javascript functions from the root page to be displayed
in the iframes. Any idea how to do this?
Jul 20 '05 #1
2 1428
Ivo
"Carl" <ca********@hot mail.com> wrote in message
news:b5******** *************** **@posting.goog le.com...
I want to load a javascript file on a root page with various iframes,
then call the javascript functions from the root page to be displayed
in the iframes. Any idea how to do this?


Both the script and calls are on the same page? That 's business as usual,
isn't it?
To call a function scripted in a parent from within a framed document, try

if (parent.myfunct ion) parent.myfuncti on(myvar);

The if-statement checks whether the function actually exists before calling
it. Once you know the various required files have loaded, this may not be
necessary.
HTH
Ivo
Jul 20 '05 #2
On 16 Feb 2004 19:21:31 -0800, Carl <ca********@hot mail.com> wrote:
I want to load a javascript file on a root page with various iframes,
then call the javascript functions from the root page to be displayed
in the iframes. Any idea how to do this?


Try reading the FAQ:

http://www.jibbering.com/faq/#FAQ4_8

Mike

--
Michael Winter
M.******@blueyo nder.co.invalid (replace ".invalid" with ".uk" to reply)
Jul 20 '05 #3

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

Similar topics

2
1815
by: Halldor Isak Gylfason | last post by:
I am faced with the task of porting a client application to a web architecture platform, e.g. to make it browser based. The technology I used was J2EE, e.g. servlets/JSP pages and HTML/javascript. The application I'm talking about is displaying data from database in grids, roughly speaking from 3 tables, that have parent-child relationship between them, and when you click on a row in a parent grid the content in the child grid should...
6
8984
by: Jane Withnolastname | last post by:
How can I include a file using JavaScript? document.write('<!--#include file="myfile.htm" -->') won't work because of the commenting. Is there a way to fool JavaScript into including the file at the appropriate point? Currently I am calling iframes instead of using SSI. You can see why I'd want to switch.
2
2788
by: dh | last post by:
How can a button that resides on the Main page tell the child Iframes to redirect without the page posting back? I keep getting a javascript error: "frames.iframe1 is null or not an object." I'm assuming this is because when i press the button it reloads the page and the frames can't be referenced. here's a simple example: <HTML> <script language="C#" runat="server">
0
1263
by: dhruba.bandopadhyay | last post by:
I know that it's possible to mix ASP & ASP.NET 1.1 in the same website/application so long as they are in separate frames (iframes). This also holds for mixing ASP & ASP.NET 2.0 pages. But what I haven't tried is mixing ASP.NET 1.1 & ASP.NET 2.0 pages in the same website/application but each page in different iframes. I don't think it's possible to to have both ASP.NET 1.1 & 2.0 pages in
2
1287
by: Joris De Groote | last post by:
Hi, I am looking for a javascript that can open a link in an iframe. However, the link on wich the user clicks, is from another iframe. So I have 2 Iframes and want to get a html page open in I2 when the user clicks on a link in I1. Is this possible with javascript? Thanks
11
2219
by: Kent Feiler | last post by:
One thing I like about frames is that they're a good place to stow Javascript. Javascript that I'd like to be around while the visible content of the screen changes goes in the frame declaration HTML file. It never needs to be reloaded and JS variables can be updated there as the visible screens progress. But...if I want to be a good internet samaritan and not use frames, what's the best way to replace that function?
4
1224
by: Moptop650 | last post by:
Is it possible to, with javascript, scroll an iframe that you do not have control of the content of? If so, how? If not, is there any other method to?
1
1365
by: muletuv | last post by:
Hi, I am creating a form that displays a different list of links depending on a value that is selected within the form. These links are contained in an iFrame and each set of links is in a div. I have written the javascript to display the relevant links but don't know how to reference the iFrame in the main page or vice versa. <form name="Form1"> <select name="topic" onChange="showLinks();"> <option value=""> Choose one </option>...
21
5640
by: wizdom | last post by:
I've tried a few things but nothing seems to work, i'm starting to think this isnt possible. I basically am looking to have the user click on the video number, then have the video load in its own section on the page. I'm currently using iframes as a work around and have been trying to read up on Ajax as another way around it. Problem is, i think using iframes i'm losing important keywords that would usually be right on the page. i initially...
0
9656
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
9498
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10366
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...
0
10173
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8993
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
7517
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...
0
6750
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4070
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
3674
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.