Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
floating div in FireFox
Old 03-15-2009, 01:39 PM floating div in FireFox
Junior Talker

Posts: 1
Trades: 0
hello, I am trying to float 3 left boxes and 3 right boxes, it works fine in IE but in FF the right boxes get shoved down. Here is my code. I am pretty new to floats so I must be doing something wrong obviously.
Thanks for your help!


<!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>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- TemplateBeginEditable name="doctitle" -->
<title>Untitled Document</title>
<style>
}
.drg #container {
}
.drg #logoheader {
float: left;
width: 260px;
height: 137px;
background: #123456;
}
.drg #logoheader1 {
float: left;
width: 260px;
height: 137px;
background: #135790;
clear: left;
}
.drg #logoheader2 {
float: left;
width: 260px;
height: 137px;
background: #246890;
clear: left;
}
.drg #logoheader3 {
float: right;
display:inline;
width: 260px;
height: 137px;
background: #357890;
}
.drg #logoheader4 {
float: right;
width: 260px;
height: 137px;
background: #468910;
clear: right;
}
.drg #logoheader5 {
float: right;
width: 260px;
height: 137px;
background: #678910;
clear: right;
}
</style>
</head>
<body class="drg">
<div id="container">
<div id="logoheader">ee</div>
<div id="logoheader1">ee</div>
<div id="logoheader2">ee</div></div>
<div id="logoheader3">ee</div>
<div id="logoheader4">ee</div>
<div id="logoheader5">ee</div></div>
</div></div>
</body>
</html>
jmsailer is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 03-15-2009, 04:59 PM Re: floating div in FireFox
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
You seem to have a surfeit of closing </div> tags
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 03-16-2009, 11:05 AM Re: floating div in FireFox
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
Quote:
it works fine in IE but in FF the right boxes get shoved down.
A word to the wise - if it looks good in IE, chances are pretty darn good it's WRONG.
Make sure it works in FF (or Opera or some other standards compliant browser) FIRST, then kick IE into submission.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 03-16-2009, 12:40 PM Re: floating div in FireFox
djura's Avatar
Super Talker

Posts: 135
Name: Darko Krsmanovic
Location: Belgrade
Trades: 0
<!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>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- TemplateBeginEditable name="doctitle" -->
<title>Untitled Document</title>
<style type="text/css">
div.container {
height:600px;
overflow:visible;
}
div.left {
float:left;
width: 260px;
}
#logoheader {
width: 260px;
height: 137px;
background: #123456;
}
#logoheader1 {
width: 260px;
height: 137px;
background: #135790;
}
#logoheader2 {
width: 260px;
height: 137px;
background: #246890;
}
div.right {
float:right;
width: 260px;
}
#logoheader3 {
width: 260px;
height: 137px;
background: #357890;
}
#logoheader4 {
width: 260px;
height: 137px;
background: #468910;
}
#logoheader5 {
width: 260px;
height: 137px;
background: #678910;
}
</style>
</head>
<body>
<div class="container">
<div class="left">
<div id="logoheader">ee</div>
<div id="logoheader1">ee</div>
<div id="logoheader2">ee</div>
</div>
<div class="right">
<div id="logoheader3">ee</div>
<div id="logoheader4">ee</div>
<div id="logoheader5">ee</div>
</div>
</div>
</body>
</html>
__________________

Please login or register to view this content. Registration is FREE
||
Please login or register to view this content. Registration is FREE
djura is offline
Reply With Quote
View Public Profile Visit djura's homepage!
 
Old 03-16-2009, 02:03 PM Re: floating div in FireFox
Skilled Talker

Posts: 87
Trades: 0
We should all start a world-wide boycott of IE... though it'll never work...
__________________

Please login or register to view this content. Registration is FREE
- The most comprehensive online resource for students and educators.
yuechen is offline
Reply With Quote
View Public Profile Visit yuechen's homepage!
 
Old 03-16-2009, 03:31 PM Re: floating div in FireFox
Skilled Talker

Posts: 77
Trades: 0
When I've had this problem, it was due to my divs being too wide with the padding/margins as different browsers have different default settings. Try decreasing the width, or remove the extra padding/margins.
__________________

Please login or register to view this content. Registration is FREE

Please login or register to view this content. Registration is FREE
whooligan is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to floating div in FireFox
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.23685 seconds with 12 queries