On Mon, 22 Dec 2003, Jeff wrote:
IFrames... I know how to use them
[If you did, you'd be ahead of the W3C, as we will see...]
BUT the trick is that I need to find a method of
providing the same information OUTSIDE of the IFrame for people who
have older browsers.
Why does everyone seem to ask for a "trick", before even finding out
whether there's a properly-engineered solution?
Any thoughts?
Like, er, read the HTML specification, with the usual critical
attention to detail.
http://www.w3.org/TR/html401/present/frames.html#h-16.5
I was thinking to simply detect the browser type/version
Well, stop thinking that at once! It can't be done if you're
otherwise conforming to web best practice (think: proxy caches), and
even if you _do_ get a user agent string, it could easily be a browser
pretending to be something else.
I just need to know which are compatible with IFrames and which
aren't.
The *browsers* already know whether they support iframes or not.
There's no need for you to duplicate this knowledge. Just supply the
properly marked-up content.
See where the W3C sets this terrible example in their spec? -
<IFRAME src="foo.html" width="400" height="500"
scrolling="auto" frameborder="1">
[Your user agent does not support frames or is currently configured
not to display frames. However, you may visit
<A href="foo.html">the related document.</A>]
</IFRAME>
Any discerning author can see that the content of the element could be
worded so as to adapt seamlessly to the situation. As TimBL himself
said way back, and it's still a good principle: "don't mention the
mechanics". And that's precisely what is wrong with the above
example, in my estimation.
http://www.w3.org/Provider/Style/
So, put your friendly content in there. Don't give the reader the
impression that you're dissatisfied with their browser - you aren't
going to win any new friends that way.