473,224 Members | 1,410 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,224 software developers and data experts.

strange behavior with IE and margin...

this is really strange... I cant find what is wrong...

so, #botonera have a left margin of 18px, but IE make it 36px!
If I put a margin of 30px, IE make it 60px!
I am crazy?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
<title>hello world</title>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />

<style type="text/css" media="screen, tv, projection">
body, html {
margin: 15px 0px 0px 0px;
padding: 0px;
background: #fff;
color: #000;
}

body {
min-width: 764px;
}

#contenedora {
background: #fff;
margin: 0 auto;
width: 764px;
height: 419px;
}

#principal {
position: relative;
background: #514c38;
float: left;
width: 382px;
height: 419px;
font: .7em Verdana, Geneva, Arial, Helvetica, sans-serif;
color: #eeeeee;
}

#contenido {
float: right;
width: 290px;
text-align: right;
padding: 0 10px 0 0;
}

#contenido h2, #contenido h3 {
padding: 0;
margin: 0;
color: #35ad9b;
font-weight: bold;
font-size: 1.1em;
}

#botonera {
float: left;
padding: 0;
margin: 0 0 0 18px;
width: 60px;
height: 34px;
border: 1px dashed #eee;
background: #eeffee;
}

#navegacion {
position: absolute;
bottom: 0;
right: 0;
padding: 0;
margin: 0 15px 15px 0;
text-align: right;
}

#navegacion ul{
margin:0;
padding:0;
list-style:none;
}

#navegacion li{
display:inline;
margin:0;
padding:0;
}

#imagen {
float: right;
width: 382px;
height: 419px;
background: #fff;
}

</style>

</head>
<body>
<div id="contenedora">

<div id="principal">
<img src="cabecera_con_d.gif" alt="" width="382" height="85" />

<div id="contenido">
<h2>Mi mamá me mima</h2>
Vamos con la descripci&oacute;n! <em>Italica</em>... <strong>negriita</strong>....<br /><br />

Fotograf&iacute;a de mate para tomar mate mammamamammama.
</div>
<div id="botonera">
<img src="enlaceportfoliooff.gif" alt="" width="60" height="17" /><br />
<img src="enlacecontactooff.gif" alt="" width="60" height="17" />
</div>
<div id="navegacion">asdsa</div>
</div>
<div id="imagen"><img src='lindafoto.jpg' alt='' align='top'/></div>

</div>

</body>
</html>

--
Luciano A. Ferrer
la**************@SacaDMEgmail.com
http://relojurbano.com.ar .algún día volverás.

.... Vencía el que se despojaba de todo.
Jun 12 '06 #1
3 2071
"Luciano A. Ferrer" <al************@arnet.com.ar> wrote:
so, #botonera have a left margin of 18px, but IE make it 36px!
If I put a margin of 30px, IE make it 60px!
I am crazy?
No, it's IE that's is crazy.
#botonera {
float: left;
margin: 0 0 0 18px;
}


If you have a style with float: left and margin-left: XX then IE will
make margin-left twice the size it should be (and the same with float:
right and margin-right)

See http://www.positioniseverything.net/...ed-margin.html
for more details and some suggested fixes.

Steve
--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <st***@pugh.net> <http://steve.pugh.net/>
Jun 12 '06 #2
Steve Pugh ha escrito lo siguiente el 12/06/2006 04:10:
#botonera {
float: left;
margin: 0 0 0 18px;
}


If you have a style with float: left and margin-left: XX then IE will
make margin-left twice the size it should be (and the same with float:
right and margin-right)

See http://www.positioniseverything.net/...ed-margin.html
for more details and some suggested fixes.


wow, thanks a lot Steve
It was the first time it happened to me, what an odd behavior... :)

--
Luciano A. Ferrer
la**************@SacaDMEgmail.com
http://relojurbano.com.ar .algún día volverás.

.... Vencía el que se despojaba de todo.
Jun 12 '06 #3
Luciano A. Ferrer wrote:
Steve Pugh ha escrito lo siguiente el 12/06/2006 04:10:
#botonera {
float: left;
margin: 0 0 0 18px;
}


If you have a style with float: left and margin-left: XX then IE will
make margin-left twice the size it should be (and the same with float:
right and margin-right)

See http://www.positioniseverything.net/...ed-margin.html
for more details and some suggested fixes.


wow, thanks a lot Steve
It was the first time it happened to me, what an odd behavior... :)


I have seen comments like that made quite often in regard to IE :)

--
"The most convoluted explanation that fits all the available and made-up
facts is the most likely to be believed by conspiracy theorists"
Jun 12 '06 #4

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

Similar topics

1
by: Hartmut J?ger | last post by:
I produce a list of tables with PHP, which outputs a lot of tables with the following HTML-Code: <table border="1" width="96%" cellspacing="0" cellpadding="0" align="center"...
9
by: Robert Misiorowski | last post by:
Hello, I have a very perplexing (at least to me) problem that hopefully someone can help me with. I'm making a site with a 3 column layout. In the middle column (my fluid column) I am trying to...
0
by: Luigi | last post by:
I would know what "criteria" is used in box positioning with the position property. Here my tries (using IE and Opera): I have a box with an absolute positioning (properties used: position,...
1
by: Luigi | last post by:
I noted a particular behavior shown by IE. Look at the simple page attached at the bottom of the post. In it, there is a box floated with the float property and another box that jumps it with the...
16
by: brian.ackermann | last post by:
Hi all, I'm working on a quick-n-dirty forum to plug into a 'strategic task planning' module I am putting together. The basics are all in place. I've gotten to a point where I can now view the...
1
by: shapper | last post by:
Hello, I have a page and two user controls: Page.aspx |--- UserControl_1.ascx |--- UserControl_2.ascx
0
by: atarumorooka | last post by:
Hello, yes..it must be hard to try and help someone else coding but today is a full week of sadness and stress for IE CSS rendering and I need your help. Here you have a link that looks nice with...
10
by: silverbob | last post by:
I am replacing my Javascript-called files with SSI, and I'm getting an unexpected result with my page footer. I can really use some help with this. The footer contains a copyright (left...
0
by: charmeda103 | last post by:
when i run my program it runs with no erorrs but the output screen is giving me strange results here is whats its giving me: CONFERENCE OVERALL RANK TEAM W-L % WINS MARGIN W-L ...
0
by: veera ravala | last post by:
ServiceNow is a powerful cloud-based platform that offers a wide range of services to help organizations manage their workflows, operations, and IT services more efficiently. At its core, ServiceNow...
0
by: VivesProcSPL | last post by:
Obviously, one of the original purposes of SQL is to make data query processing easy. The language uses many English-like terms and syntax in an effort to make it easy to learn, particularly for...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 3 Jan 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). For other local times, please check World Time Buddy In...
0
by: mar23 | last post by:
Here's the situation. I have a form called frmDiceInventory with subform called subfrmDice. The subform's control source is linked to a query called qryDiceInventory. I've been trying to pick up the...
0
by: abbasky | last post by:
### Vandf component communication method one: data sharing ​ Vandf components can achieve data exchange through data sharing, state sharing, events, and other methods. Vandf's data exchange method...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: fareedcanada | last post by:
Hello I am trying to split number on their count. suppose i have 121314151617 (12cnt) then number should be split like 12,13,14,15,16,17 and if 11314151617 (11cnt) then should be split like...
1
by: davi5007 | last post by:
Hi, Basically, I am trying to automate a field named TraceabilityNo into a web page from an access form. I've got the serial held in the variable strSearchString. How can I get this into the...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....

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.