473,379 Members | 1,191 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,379 software developers and data experts.

CSS padding quirk?

Hi all,

I've noticed that the CSS padding attribute for DIV
works differently on different browsers. Actually, so
does the left attribute.

On Firefox, padding is added to the entire width
of a DIV, whereas in IE 6.0, it is not.

As for left, the default left value in Firefox
if left unspecified is 0, whereas in IE 6 it isn't.

Has anyone else noticed this?

Thanks,
Vesp
Jul 23 '05 #1
3 1173
Yeah, it's been like this since netscape was big. I am not surprised that
no one at MS has decided to fix this. They always do things, just a HAIR
different. Cross browser javascript code is the way to go on this one my
friend. Client side scripting at it's fullest!

Qz

"Vespasian" <ve***@klsaldjfldskjfkldjf.org> wrote in message
news:WJ********************@comcast.com...
Hi all,

I've noticed that the CSS padding attribute for DIV
works differently on different browsers. Actually, so
does the left attribute.

On Firefox, padding is added to the entire width
of a DIV, whereas in IE 6.0, it is not.

As for left, the default left value in Firefox
if left unspecified is 0, whereas in IE 6 it isn't.

Has anyone else noticed this?

Thanks,
Vesp

Jul 23 '05 #2
VK
IE tried to lock the privacy vulnerability
<https://bugzilla.mozilla.org/show_bug.cgi?id=147777> w/o success, just
more mess in its model.

It seems to be nor fixable

Jul 23 '05 #3
On 03/06/2005 16:50, Vespasian wrote:

[snip]
On Firefox, padding is added to the entire width
of a DIV, whereas in IE 6.0, it is not.


When IE6 is put into Standards mode by including a complete DOCTYPE
declaration, it will act correctly. However, earlier versions will
always use the broken model.

Google "Box model" for more information.

[snip]

Mike

--
Michael Winter
Replace ".invalid" with ".uk" to reply by e-mail.
Jul 23 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Thresh | last post by:
Hi all, two problems that I've been wrestling with: 1) I've got some images on a site that are links. I've got them set for 2px of padding, and a 1px border. The color changes upon hover. This...
0
by: Red | last post by:
This is apparently an ie display bug, I can't seem to figure out which ie bug this is. a 3 sided border is created by wrapping the 'inner' box in the 'middle' box and padding the 'middle' box...
2
by: Knoxy | last post by:
Hello, I've noticed one or two people post on this before but nobody seems to have replied so raising the issue again... is this a known IE6 CSS bug? I have placed the following in my...
4
by: Wilhelm Kutting | last post by:
hi, when i use the padding-left attribut, i like to overwrite a default value like that ..padding30 {margin-left: 30px;} ..padding0 {margin-left: 0px;} <div class="padding30"> Padding 30...
4
by: mux | last post by:
Hi I found out that the following piece of code throws an error. 1 #include "stdio.h" 2 3 int main() 4 { 5 int a,b; 6 a= 10;
13
by: Amarendra | last post by:
Folks, This structure padding issue is bothering me now, could not locate a satisfactory answer on clc, so here it goes... I have a structure, given below: typedef struct { int flag; char...
36
by: phil-news-nospam | last post by:
Here is a simpler (no drop shadows) example of the padding bug I see: http://phil.ipal.org/usenet/ciwas/2006-05-08/buttons-1.html So far I find nothing in the CSS2 document that says I should...
12
by: Kislay | last post by:
case 1 : struct s { char c1; // 8 double d; // 8 int i1; // 4 char c2; // 4 int i2; // 4 };
14
by: Mark Shroyer | last post by:
I just noticed an unintuitive aspect of how nested blocks are positioned under a specific set of conditions, and although this is ostensibly correct behavior (unless Firefox, Safari, and Opera are...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.