Forum Moderators: open
i have developed a few sites now. using html css and php. (still very much learning).
whenever i build a table for a site to sit in (instead of using divs), the site seems to sit slightly left and down, instead of filling the whole page as i would want it too.
Its like the browser has its own 'padding' and forces the table to sit on an offset, whereas with divs i can alter that.
I was wondering is there anyway to stop the browser padding my table away from the browser edges?
And part two.
If i build a site in firefox, and then switch over to IE they look slightly different. images not stretching as far, tables not as wide or as long.
in firefox my site can fit perfectly and look how i want it too. but when i open it in IE there is an inch difference in width, the page just doesn't fill properly.
is there anyway to avoid this?
Please any tips or advice, or links to articles that you think would help would be greatly appreciated.
- Adam White
<style>
body {margin:0;padding:0;}
</style> The padding issue sounds like you are in Quirks mode. I'd advise you to set a correct DOC TYPE as the first line of your HTML before you continue and then see if those width difference are cut down. If you want to use the Quirks mode, you'll find that the problem is that IE is treating width as the entire width of the object, and not the width of the content within the object (excluding the padding, margin, etc.)
as for doc type, i don't fully understand them, but i grasped a larger understanding from a search on these forums. mine was set to:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
thanx for the response.