PDA

View Full Version : Iframe and spacing



larsfoto
30 Apr 2010, 02:54 AM
I try to do a page with a top line with links and Iframe showing flash file underneath. I'd like the top line to be just above the frame, but now there is a small white border on top of the Iframe that I want to get rid of. Anyone that can help me with a solution? Both menu and Iframe are in a table cell.

Page is here:

http://frifoto.no/ny/

coiner
30 Apr 2010, 01:42 PM
First, to get rid of the iframe border, set the "frameborder" attribute to 0 in the iframe tag and add "border: 0px" to its css.

As for the rest of your code, tables are gross and outdated in my opinion, you should use divs and floats to achieve the design you want. Most importantly, do not use fixed margins for your page, it will look good in one resolution but not others. For example, I just went to it using 1024x768 and half of your site is off the page. Instead, set the margin of your main container to "margin: ?px auto;" changing the '?' to whatever you want your top margin to be. This will auto-center the container on the page.