Webmaster Forum

Go Back   Webmaster Forum > Web Development > Coding Forum

Coding Forum Problems with your code? Discuss coding issues, including JavaScript, PHP & MySQL, HTML & CSS, Flash & ActionScript, and more.


Reply
 
LinkBack Thread Tools Display Modes
Old 02-15-2007, 08:29 PM   #1 (permalink)
v7n Mentor
 
Sketch's Avatar
 
Join Date: 05-06-04
Location: London, UK
Posts: 664
iTrader: 0 / 0%
Latest Blog:
None

Sketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web pro
Unhappy CSS Issue

So I thought its about time I learnt how to code without tables... It isn't had hard, but at the same time there is something that I just cannot figure out.

I'm working on a layout http://www.sketchthat.com/dev/ and in IE it works fine however in Firefox its not working correctly and I'm not sure why.

I think it has something to do with the #body style, because when I add the height in there it will work in firefox, but I want the height to be fluid (i hope thats the correct word), I need to to change size depending on how many adds are shown.

If anyone can help me that would be fantastic!!!

I won't post the code because its a bit long, but you'll be able to see it by visiting the page then viewing the source.

Thanks in advance
Sketch is offline  
Add Post to del.icio.us
Reply With Quote
Old 02-16-2007, 12:02 AM   #2 (permalink)
Senior Member
 
SEOclown's Avatar
 
Join Date: 05-11-06
Posts: 216
iTrader: 0 / 0%
SEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really nice
Are you sure the problem is with the CSS? I could be terribly wrong but my guess is it has something to do with the (div)
Code:
<body> <div id="header"> Login | Advertisers | Contact Us | About Us </div><div id="navigation"> <b>Find sales in: </b> <a href="#">Victoria</a> | <a href="#">New South Wales</a> | <a href="#">Queensland</a> | <a href="#">Tasmania</a> | <a href="#">South Australia</a> | <a href="#">Northern Territory</a> | <a href="#">Western Australia</a> </div> <div id="main_add"> <div class="top"><div></div></div>
Maybe you need to remove one or something in here? Its like they are cancelling themselves out you know. Or i have no clue but thats all i can come up with.
SEOclown is offline  
Add Post to del.icio.us
Reply With Quote
Old 02-16-2007, 12:05 AM   #3 (permalink)
v7n Mentor
 
Sketch's Avatar
 
Join Date: 05-06-04
Location: London, UK
Posts: 664
iTrader: 0 / 0%
Latest Blog:
None

Sketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web pro
Each of those divs closes itself...So there shouldn't be any problem there??

Code:
<div class="top"><div></div></div>
The only reason that div is in their is because it does one of my rounded corners. I read a tutorial and thats what it told me to do
Sketch is offline  
Add Post to del.icio.us
Reply With Quote
Old 02-16-2007, 12:49 AM   #4 (permalink)
Senior Member
 
SEOclown's Avatar
 
Join Date: 05-11-06
Posts: 216
iTrader: 0 / 0%
SEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really niceSEOclown is just really nice
Yeah by looking at it thats all i was thinking, The divs close itself but maybe one needs to be open?

Oh, Thats how you make round corners, i was wondering because it looks as though it just cancells each other out.

Im sure someone has the answer, sorry i wasnt of more help.
SEOclown is offline  
Add Post to del.icio.us
Reply With Quote
Old 02-16-2007, 10:32 AM   #5 (permalink)
v7n Mentor
 
Taltos's Avatar
 
Join Date: 11-22-06
Location: Phoenix, AZ
Posts: 1,784
iTrader: 0 / 0%
Latest Blog:
None

Taltos is a highly respected web proTaltos is a highly respected web proTaltos is a highly respected web proTaltos is a highly respected web proTaltos is a highly respected web proTaltos is a highly respected web proTaltos is a highly respected web proTaltos is a highly respected web proTaltos is a highly respected web proTaltos is a highly respected web proTaltos is a highly respected web pro
I have been fighting similar problems lately. IE7 does what I expect from my code and FF is doing bizarre things. It's all backwards now

The first thing I would try is call that ID something besides "body". I never like to see duplicate names even when they SHOULDN'T conflict. Just out of curiosity, have you tried just using height: 100% if you want it fluid but need seem to need a height to make FF cooperate?
__________________
Experimenting
Taltos is offline  
Add Post to del.icio.us
Reply With Quote
Old 02-16-2007, 05:34 PM   #6 (permalink)
v7n Mentor
 
Sketch's Avatar
 
Join Date: 05-06-04
Location: London, UK
Posts: 664
iTrader: 0 / 0%
Latest Blog:
None

Sketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web proSketch is a highly respected web pro
I ran the code through the validator and i had a lot of problems, but after fixing them all it still hasn't helped my little FF issue.

I've also changed the name of body to main_body so that the names aren't being reused.

Last edited by Sketch; 02-16-2007 at 05:50 PM..
Sketch is offline  
Add Post to del.icio.us
Reply With Quote
Old 02-16-2007, 06:08 PM   #7 (permalink)
Contributing Member
 
Join Date: 02-15-07
Posts: 88
iTrader: 0 / 0%
Latest Blog:
None

atox is on the right pathatox is on the right path
This should solve it

Code:
<div id="main_add"> <div class="top"><div></div></div> <div id="main_body"> <ul> <li><a href="#"><img src="sample_add.gif" width="200" height="156" alt="" /><b>Xbox 360</b><label>Proin id pede sed felis blandit aliquam. Nam auctor tellus quis nunc. Praesent ultrices.</label></a></li> <li><a href="#"><img src="sample_add.gif" width="200" height="156" alt="" /><b>Xbox 360</b><label>Proin id pede sed felis blandit aliquam. Nam auctor tellus quis nunc. Praesent ultrices.</label></a></li> <li><a href="#"><img src="sample_add.gif" width="200" height="156" alt="" /><b>Xbox 360</b><label>Proin id pede sed felis blandit aliquam. Nam auctor tellus quis nunc. Praesent ultrices.</label></a></li> <li><a href="#"><img src="sample_add.gif" width="200" height="156" alt="" /><b>Xbox 360</b><label>Proin id pede sed felis blandit aliquam. Nam auctor tellus quis nunc. Praesent ultrices.</label></a></li> <li><a href="#"><img src="sample_add.gif" width="200" height="156" alt="" /><b>Xbox 360</b><label>Proin id pede sed felis blandit aliquam. Nam auctor tellus quis nunc. Praesent ultrices.</label></a></li> <li><a href="#"><img src="sample_add.gif" width="200" height="156" alt="" /><b>Xbox 360</b><label>Proin id pede sed felis blandit aliquam. Nam auctor tellus quis nunc. Praesent ultrices.</label></a></li> <li><a href="#"><img src="sample_add.gif" width="200" height="156" alt="" /><b>Xbox 360</b><label>Proin id pede sed felis blandit aliquam. Nam auctor tellus quis nunc. Praesent ultrices.</label></a></li> <li><a href="#"><img src="sample_add.gif" width="200" height="156" alt="" /><b>Xbox 360</b><label>Proin id pede sed felis blandit aliquam. Nam auctor tellus quis nunc. Praesent ultrices.</label></a></li> <li><a href="#"><img src="sample_add.gif" width="200" height="156" alt="" /><b>Xbox 360</b><label>Proin id pede sed felis blandit aliquam. Nam auctor tellus quis nunc. Praesent ultrices.</label></a></li> </ul><div style="clear:both; height:0px; overflow:hidden">&nbsp;</div> </div> <div class="bot"><div></div></div> </div>
atox is offline  
Add Post to del.icio.us
Reply With Quote
Old 02-16-2007, 06:13 PM   #8 (permalink)
Contributing Member
 
Join Date: 02-15-07
Posts: 88
iTrader: 0 / 0%
Latest Blog:
None

atox is on the right pathatox is on the right path
Cleaner solution

Forget adding the extra div, that's unnec. markup. Just add
Code:
.bot {clear:both}
to your css and all should be fine
atox is offline  
Add Post to del.icio.us
Reply With Quote
Go Back   Webmaster Forum > Web Development > Coding Forum

Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
www and non www issue webexplore Google Forum 9 09-15-2007 05:59 PM
WOMD - Issue or Non-issue John Scott Controversial Social Issues 1 08-02-2007 09:30 AM
Help with a possible CSS issue Mr.Bill Coding Forum 5 07-24-2007 05:35 PM
css issue in IE6 sachi Coding Forum 8 02-05-2007 12:57 PM
CSS issue Laurentvw Coding Forum 3 04-03-2006 10:46 AM


Sponsor Links
Get exposure! Contextual Links V7N SEO Blog V7N Directory


All times are GMT -7. The time now is 01:37 AM.
© Copyright 2008 V7 Inc
Powered by vBulletin
Copyright © 2000-2009 Jelsoft Enterprises Limited.


Search Engine Optimization by vBSEO 3.3.0 ©2009, Crawlability, Inc.