Solved

Creating IFrames

Posted on 2000-03-07
4
842 Views
Last Modified: 2008-03-10
Hi,
I want to create IFrames at runtime.
I used document.write("<IFrame ...></IFrame>").
It worked fine. Each IFrames has set of links and caption. So,I've to create 2 rows for each IFrame.What is the best way to do this?.
One way is creating a table inside each IFrame and the other way is create two <Div> tags .One for the caption and other for the links.These 2 div tags should be inside the IFrame.

Is there any other way to do this?.
I'm creating the IFrame at runtime.
Any ideas/suggestions can be very useful for me.
Thanks in advance.
0
Comment
Question by:tmmet
  • 2
  • 2
4 Comments
 

Accepted Solution

by:
remibrom earned 50 total points
Comment Utility
I would suggest coding the tables for each IFRAME in an external file and then having the IFRAME link to the file -- thus, you would have <IFRAME SRC="stuff.html">
This approach would make updating the links easy, as you would only have to edit the external file, you would leave the IFRAME alone.  This may not work if you create the links and IFRAME contents at run-time, though.  If you do that, I suggest using the DIVs, because they are easy and work well with IFRAMEs -- unless you want borders for each "cell", in which case a table is the obvious choice.
0
 

Author Comment

by:tmmet
Comment Utility
Hi,
Thanks for our reply.how can I embed 2 DIV tags inside my IFrame?.I tried using document.all.myIFrame.innerHTML = ....
Its giving error.Any ideas/suggestions will be greatly helpful for me.Thanks in advance.
0
 

Author Comment

by:tmmet
Comment Utility
Hi,
Thanks for our reply.how can I embed 2 DIV tags inside my IFrame?.I tried using document.all.myIFrame.innerHTML = ....
Its giving error.Any ideas/suggestions will be greatly helpful for me.Thanks in advance.
0
 

Expert Comment

by:remibrom
Comment Utility
Ah, so you ARE embedding at run time.  To change HTML (including DIVs) at runtime, check at http://msdn.microsoft.com/msdn-online/workshop/author/dhtml/reference/properties/innerHTML.asp
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Convert a Master Page to HTML 16 59
2 CSS questions 11 33
Image not there 4 32
Paper tearing animation 6 38
Popularity Can Be Measured Sometimes we deal with questions of popularity, and we need a way to collect opinions from our clients.  This article shows a simple teaching example of how we might elect a favorite color by letting our clients vote for …
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this tutorial viewers will learn how add a full-size background image to a webpage using CSS3. Create a new HTML document with an internal stylesheet.: In CSS, define the html element to have a background image. Use a high resolution image.: In t…
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

7 Experts available now in Live!

Get 1:1 Help Now