PDA

View Full Version : Question on Iframes


2bz2p
08-05-2008, 01:04 AM
Hi,

So I know that using Iframes is not best practice, though I just came across a situation were the website called FSHost has a server status page and it is created on the fly so you can say go through the source code and copy the code into a div. So it has to be in a iframe, so my question is what replaced the iframe?

Thanks
2b

davidj
08-05-2008, 06:00 AM
the reason Frames became the spawn of Satan was because of SEO

there is a risk that the page called into the Iframe may get index above the main page

Frames were defined in order to allow the content to scroll where the banners and menus would be fixed and would not scroll or refresh.

Scrolling Divs are favoured now

2bz2p
08-05-2008, 01:15 PM
So when you have to include a dynamic page (i.e. Flight Server Info) you just have to break the rules and put in an Iframe.

Oh well, the layout for that site is tables anyway.

Thanks
2b

domedia
08-05-2008, 01:17 PM
So it has to be in a iframe, so my question is what replaced the iframe? If you want to 'attach' an external page to your site, yes this is the way.

There's better ways, but that requires the other site to have an API or feed available for you so you can manipulate the data yourself.

So when you have to include a dynamic page (i.e. Flight Server Info) you just have to break the rules and put in an Iframe.What rule are you breaking? You're missing the point :)

davidj
08-05-2008, 02:11 PM
if your working in PHP (which i know you are) why not just include the file into the main page

domedia
08-05-2008, 02:20 PM
if your working in PHP (which i know you are) why not just include the file into the main page Because it's an external HTML page. You cannot include a full HTML page inside a HTML page like that. Well you can but the result won't be a html document. This is a perfect example of when it's ok to use frames.

davidj
08-05-2008, 02:26 PM
Sorry

misunderstood

why not look into scraping the page.

2bz2p
08-05-2008, 11:08 PM
What rule are you breaking? You're missing the point :)

Its not that I am breaking any rules I guess I just want to be able to stay up to date on what the standard is, if you will.

I missunderstood that Iframes are used like tables where its the best choice/tabular data. I thought that Iframe tags were becoming deprecated, dont ask where I got that from though cant remember, so yeah it may have been an asumption in my head :roll:

Sorry

misunderstood

why not look into scraping the page.

Its not part of the vpilot app, its another VA website that I am helping out on. I wouldnt add that as a feature, if added would be a link

Thanks Yall
2b

domedia
08-06-2008, 09:03 PM
Its not that I am breaking any rules I guess I just want to be able to stay up to date on what the standard is, if you will. iframes and frames are part of the html protocol :)

I missunderstood that Iframes are used like tables where its the best choice/tabular data. I thought that Iframe tags were becoming deprecated, dont ask where I got that from though cant remember, so yeah it may have been an asumption in my head :roll: They're both unpopular because they are misused all the time. Many people still use tables and frames for layout purposes, instead of CSS. :)

2bz2p
08-11-2008, 02:47 PM
So really if you know how to use them correctly then there accepted. CSS is for layouts, Tables are for tabular data, and Iframes are for pages that need to be added, but not for layout purposes.

Thanks again
2b

Corrosive
08-11-2008, 04:51 PM
Lesson to be learned: I work for a large motoring organisation in the UK and we are owned ny a major insurer. Anyhoo, we have inherited their intranet. It has a lovely flash menu in the top frame and all the other pages are displayed in the main body. It works for navigation, then you find something useful and you can't bookmark it. The bookmark stays as the home page so you have to remember where it is and hope you can find it later. It renders the intranet pretty much useless. Someone's head should roll :wink:

Rob_Che
08-15-2008, 03:40 PM
...you can't bookmark it. The bookmark stays as the home page ...


yep. and if you right click and bookmark in the frame you don't get and navigation ! awesome ! frames rock.