Hi Have some JS
with(milonic=new menuname("Links")){
style=menuStyle;
aI("text=NEW Apache;url=http://www.apache.org;target=_new");
aI("text=iframe Apache;url=javascript:openIFrame('tempiframe','http://www.apache.org/')");
aI("text=iframe myfile;url=javascript:openIFrame('tempiframe','me.htm')");
aI("text=myfile;url=me.htm;target=tempiframe");
}
which plays around with IFRAME as in the sample
http://milonic.com/menusample.php?sampleid=11
the first one loads a new window...thats cool
the second one opens it in the iframe...thats cool
the third opens me.htm in the iframe...that cool
the fourth one opens a new window which I not sure why given that the target is the name of the IFRAME "tempiframe")
Any help would be appreciated. I have searched thru the forum already..
Regards
Mick
IFRAME question
- fredlongworthhighschool
- Mega Advanced
- Posts: 362
- Joined: Fri Jun 27, 2003 11:34 am
- Location: Manchester, England.
- Contact:
Re: IFRAME question
Is it because your last link doesn't have url=javascript:openIFrame in it?mjordan wrote:Hi Have some JS
with(milonic=new menuname("Links")){
style=menuStyle;
aI("text=NEW Apache;url=http://www.apache.org;target=_new");
aI("text=iframe Apache;url=javascript:openIFrame('tempiframe','http://www.apache.org/')");
aI("text=iframe myfile;url=javascript:openIFrame('tempiframe','me.htm')");
aI("text=myfile;url=me.htm;target=tempiframe");
}
Andy Davis
Web Designer & Smartboard Manager
Fred Longworth High School, Manchester, England.
Web Designer & Smartboard Manager
Fred Longworth High School, Manchester, England.
Thanx Andy,
Just thought I could target the Iframe directly...obvioulsy not...thanx for you assistance
BTW...I use Frontpage to do my design and have noticed that the third menu
aI("text=iframe myfile;url=javascript:openIFrame('tempiframe','me.htm')");
doesnt display the contents of the iFrame when I select the menu item in "Preview"...i.e. I have to load the page into a browser before it will work
Thanx
Mick
Just thought I could target the Iframe directly...obvioulsy not...thanx for you assistance
BTW...I use Frontpage to do my design and have noticed that the third menu
aI("text=iframe myfile;url=javascript:openIFrame('tempiframe','me.htm')");
doesnt display the contents of the iFrame when I select the menu item in "Preview"...i.e. I have to load the page into a browser before it will work
Thanx
Mick
- fredlongworthhighschool
- Mega Advanced
- Posts: 362
- Joined: Fri Jun 27, 2003 11:34 am
- Location: Manchester, England.
- Contact:
It's funny, I also use Iframes but I don't use the method you do. A typical link of mine is as follows:
Code: Select all
aI("text=July 2003;url=news/newsletter_july.htm;status=News for July 2003;target=fred")
Andy Davis
Web Designer & Smartboard Manager
Fred Longworth High School, Manchester, England.
Web Designer & Smartboard Manager
Fred Longworth High School, Manchester, England.
You gotta have a frame or iframe somewhere on the page (or even another window) with its ID set to whatever you specify in the target. When the link is called upon, it will take the target and look for a frame, iframe, or open IE window with that ID, and load the URL in that. If it cannot find a match, it will open a new window and assign the window whatever was specified in the target. Hope that helps.
Dave Hergert
Software Engineer
"Helping to make the menu better, one at a time."
Software Engineer
"Helping to make the menu better, one at a time."