Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Linebreak adds space between inline div on FireFox 2

Status
Not open for further replies.

Sleidia

Technical User
May 4, 2001
1,284
FR
Hi guys :)

On FireFox (but not on IE6)

Code:
<div style="display:inline">1</div>
<div style="display:inline">2</div>

Produces : 1 2

... but ...

Code:
<div style="display:inline">1</div><div style="display:inline">2</div>

Produces : 12

Can I get rid of the extra space between 1 and 2 without having to remove the linebreak (for code readability)?

Thanks :)
 
If you float both of those divs left, it will remove the space.

[monkey][snake] <.
 
Hi

Sleidia said:
On FireFox (but not on IE6)
I would change the wording : on Explorer ( but not on other browsers ). Because Opera and Safari certainly acts like Mozillas.

The only way I know :
Code:
<div style="display:inline">1</div
><div style="display:inline">2</div>

Feherke.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top