Start learning with our library of video tutorials taught by experts. Get started
Viewed by members. in countries. members currently watching.
In XHTML and HTML Essential Training, Bill Weinman helps designers and coders understand XHTML and HTML. In the process, Bill covers document structure, block and inline-level tags, floating images, controlling white space, phrase and font markup, and tables and frames. He even provides a good introduction to CSS. Bill offers step-by-step guidance for building a complete working web site. Exercise files accompany the course.
In the last lesson we created this page here, which is the frames page, and it has these different documents in the different frames, and we explained how all of that works. And you'll notice that it has these lovely borders here, when I hover the mouse over them, the pointer changes to something that I can drag. So I can actually resize these borders, and that's not necessarily what you want when you're creating a frames document. Most people would rather have their frames document look like this with no borders whatsoever, and all their pages are nicely butted up against each other. So they blend together and you can even do nice things with your graphics to make them merge, so that it looks very coherent and then when I click on these links, you'll see that they all show up in the content area just all nicely merged together.
So most people would like to have that rather than this. Now the problem with this is you'll notice that it says your Frames Example (not valid), and that's because that's the title that I gave the document, because there is XHTML in there that's actually not valid XHTML and that is necessary to get this effect. The problem is that the XHTML standard does not include the facility to make these borders go away. So here is the valid example, and this is as close as you can get to with valid XHTML, and you'll notice it still has this border, and I can still grab it, and I can still move things around which is not at all what you want when you're trying to get this effect here.
So just as long as you understand that this is breaking the rules, and that it works in every browser I've tried it in, and the browser companies of course are more interested in having it work than in having it satisfy the standards committee, and so am I, and so are you. So we'll go ahead and I'll show you how this works, and just understand, you should try it in all the browsers that matter to you and make sure that it actually works in all those browsers. As of this recording, it works in all the browsers that I've tried it in. So here is the XHTML that I'm talking about, and this is a frameset document, and you'll notice that the only difference here between this one and the one that we looked out before is that it has this border="0" attribute, and it's just in this one place in this frameset.
It doesn't really need to be in any of the other framesets or any of the other frames, or anywhere else in the document, and really that is the entire trick. The problem of course is that that attribute is not defined with this tag. And so, if you try to run it through one of those automated validated things that the standard committees would like you to be using, that I haven't even shown you where they are, you'll find that it doesn't validate, and that's really the only problem which is not a problem, because it works in the browsers, and that's what matters. So this is how you do that. I'm going to show you the valid version here, which has this frameborder="0", on each of the frames and that actually makes it stop displaying that gray border that we saw in this original one.
And instead, it gives you this white border, which doesn't really help much, and so that's what the standard version of it does. The not valid version of it is the one that works, and this has the Border="0" attribute, and it looks like this in the browser. So that's how you make the border go away, and as I said, it works in all the browsers that I know of, and it is not a part of the XHTML standard.
Find answers to the most frequently asked questions about XHTML and HTML Essential Training.
Here are the FAQs that matched your search "":
Sorry, there are no matches for your search ""—to search again, type in another word or phrase and click search.
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.
Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.