Frames Tutor- No thin lines

The problem: you try to set frame borders to zero, but a thin line still appears between frames in some browsers.

The solution: set everything to zero. Sometimes different browsers understand different things. By covering everything that any browser might understand, you solve the problem. The only time this won't work completely is if you have fairly complex framesets. In that case there's often a stubborn remaining line that just won't go away no matter how hard you try.

Consider this example.

Here is the code for that page...

    <FRAMESET ROWS="60,*">
      <FRAME SRC="doc1.html" NAME="top">
      <FRAMESET COLS="160,*">
        <FRAME SRC="doc2.html" NAME="left">
        <FRAME SRC="doc3.html" NAME="main">
      </FRAMESET>
    </FRAMESET>

Now we'll set everything we possibly can to zero...

To the `<FRAMESET>` tags we'll add
`BORDER=0 SPACING=0 FRAMEBORDER=0 FRAMESPACING=0`

And to the `<FRAME>` tags we'll add
`BORDER=0 SPACING=0 FRAMEBORDER=0 FRAMESPACING=0 MARGINWIDTH=0 MARGINHEIGHT=0`

    <FRAMESET ROWS="60,*" BORDER=0 SPACING=0 FRAMEBORDER=0 FRAMESPACING=0 >
      <FRAME SRC="doc1.html" NAME="top" BORDER=0 SPACING=0 FRAMEBORDER=0 FRAMESPACING=0 MARGINWIDTH=0 MARGINHEIGHT=0 >
      <FRAMESET COLS="160,*" BORDER=0 SPACING=0 FRAMEBORDER=0 FRAMESPACING=0 >
        <FRAME SRC="doc2.html" NAME="left" BORDER=0 SPACING=0 FRAMEBORDER=0 FRAMESPACING=0 MARGINWIDTH=0 MARGINHEIGHT=0 >
        <FRAME SRC="doc3.html" NAME="main" BORDER=0 SPACING=0 FRAMEBORDER=0 FRAMESPACING=0 MARGINWIDTH=0 MARGINHEIGHT=0 >
      </FRAMESET>
    </FRAMESET>

Now look at it. It should now be line free in at least most browsers.

General Table of Contents | Lessons Intro - 1 - 2 - 3 - 4 - 5 - 6 - 7 | Templates | Barebones HTML Guide
PROFESSIONAL WEB DESIGN