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
IE 7 clear:both problem
Old 08-12-2007, 11:24 PM IE 7 clear:both problem
Average Talker

Posts: 17
Name: Sam
Trades: 0
Could look at the following page in IE 7.
http://www.youngamericangrowers.com/...der_search.asp

I used the following style to clear the div after each plant listing.

.basement:after {
content: ".";
display: block;
height: 0;
clear: both;
visibility: hidden;
}

This worked for IE6, firefox and on mac browsers. When IE 7 came out it messes this page up bigtime. Several people on the web suggested to add this line in addition to the above class but it does not work for me.

.basement{display: inline-block;}

Anyone have any ideas, suggestions?
jughead2279 is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 08-13-2007, 01:59 AM Re: IE 7 clear:both problem
ADAM Web Design's Avatar
Canadastaninianite

Posts: 5,935
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
Trades: 0
You need to put your clearing immediately after your last floated object (in this case, the right floated div on each row).

Also...you don't need to specify position: relative. It's not doing anything in this case.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
(my blog)


Please login or register to view this content. Registration is FREE
(with proof)
ADAM Web Design is offline
Reply With Quote
View Public Profile Visit ADAM Web Design's homepage!
 
Old 08-13-2007, 06:46 PM Re: IE 7 clear:both problem
Average Talker

Posts: 17
Name: Sam
Trades: 0
Adam,

No dice...if I interpreted your suggestion correctly this is what i did
new code:

<div>
<div style="float:right;width:353px;position:relative;" >
html code...
</div>
<div class="basement"></div>
</div>
<br>
<hr>

old code:
<div>
<div style="float:right;width:353px;position:relative;" >
html code...
</div>
</div>
<div class="basement"></div>
<br>
<hr>

any other ideas?



Last edited by jughead2279; 08-13-2007 at 06:54 PM.. Reason: extra html
jughead2279 is offline
Reply With Quote
View Public Profile
 
Old 08-13-2007, 09:33 PM Re: IE 7 clear:both problem
Average Talker

Posts: 17
Name: Sam
Trades: 0
see next post

Last edited by jughead2279; 08-13-2007 at 09:38 PM.. Reason: incorrect message
jughead2279 is offline
Reply With Quote
View Public Profile
 
Old 08-13-2007, 09:36 PM Re: IE 7 clear:both problem
Average Talker

Posts: 17
Name: Sam
Trades: 0
I found a workaround for my particular problem. I am a newb to css so I don't know if this will be frowned upon.

I added my basement class (clear fix) to the containing div in addition to having the basement directly after the div. The code goes something like this.

<div class="basement">
<div>image...</div>
<div>plant html code....</div>
</div>
<div class="basement"></div>
jughead2279 is offline
Reply With Quote
View Public Profile
 
Old 08-13-2007, 11:27 PM Re: IE 7 clear:both problem
ADAM Web Design's Avatar
Canadastaninianite

Posts: 5,935
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
Trades: 0
Actually, that's not quite what I had in mind. I'll code it for you and maybe you'll see it better.
Code:
<div>
<left floated div></div>
<right floated div></div>
<clearing div></div>
</div>
You don't actually need the containing div itself...I just like it because it organizes code a bit better for my own eyes.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
(my blog)


Please login or register to view this content. Registration is FREE
(with proof)
ADAM Web Design is offline
Reply With Quote
View Public Profile Visit ADAM Web Design's homepage!
 
Reply     « Reply to IE 7 clear:both problem
 

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.28014 seconds with 12 queries