<iframe> </iframe>
iFrames were popular some years ago, sometimes whole sites were built using them, but they were more of a novelity than anything else and over time they have fallen by the wayside. At the moment they are mostly used for third party advertising and code snippits.
iFrames allow you to dynamically change content within a page without the use of additional scripting . With iFrames you are able to load a page into a section of another page.
Although W3C has discarded frames for html5 it has still retained iframes which now include a couple of improvements.
What are iFrames
- iFrames are an inline element
- iFrames allows you to embed a document into an existing page
- iFrames allow different types of documents to be embedded (html, pdf, etc)
- iFrames allow the embeded document to appear to be part of the existing page.
- iFrames allow users to scroll within the frame
- iFrames allow for easy editing of the external content
Why use an iFrame
- External Advertisments
- Snippits of Code
- Embedded Content from Another Site
- A Section of a Page that is Common to other Pages , header, footer etc.
- Videos
Its easy to embed youTube Videos into iFrames
- Portfolios - When your images are used as a background of the loading page it is harder for them to be downloaded by the user (but not impossible)
- Content that is continually edited