Jump to content

Css frustration! Help please


Griffey
 Share

Recommended Posts

Sup guysJust a smalll little problem I hope one of you have the answer to. I've been trying to puzzle it out myself, but for the life of me can't figure it out!Here's my site url http://members.shaw.ca/griffeymike/The problem is that in firefox the #wrap container which i specified to hold all my content is not positioned directly against the top of the page(as it is in IE versions). Any help would be appreciated. The css code is posted below.CSSbody,html{margin: 0px;padding: 0px;background-color: #99CC00;color: #669999;}#wrap{background-color: #99c;margin: 0 auto;width: 750px;}#header{background-color:#00FF66;}#nav{background-color:#FF9966;}#main{background-color:#99c;float: left;width: 500px;}#sidebar{background-color:#0066CC;float: right;width: 250px;}#footer{background-color:#663333;clear: both;}

Link to comment
Share on other sites

:) that's not your wrap's fault. it is on top already. but the h3 make the header div away from top.try this
<h3 style="margin-top:0;">Website Design Without Frustration!</h3>

or put some inline element before h3

Thanks for the solution, it worked perfectly. It's much appreciated.Mike
Link to comment
Share on other sites

Looking at the site I created again, I saw the same problem occur,(this time in both firefox and internet explorer) with the UL tag. It's frustrating learning all the little differences associated with different browsers and what works or not. I've found that it's easier just to position one thing at a time and then check my work in the different browsers to make sure everythings alright before proceeding on to the next step.Anyway, I just stumbled upon an article which kind of adressed that concern, but I'd like to get some feedback on it from some of the professionals on this board. He suggested that because of the different margins and padding that different browsers display, you insert the following css:*{margin: 0;padding: 0}My question would be is this actually worth doing? Does it save in the overall time it makes to create the site because less problems arise(as everythings more uniform across all browsers), or is this actually a bad technique because it requires more coding to to specify padding/margins for whatever div, element that needs adjusting. Any thoughts on this would be appreciated.

Link to comment
Share on other sites

Looking at the site I created again, I saw the same problem occur,(this time in both firefox and internet explorer) with the UL tag. It's frustrating learning all the little differences associated with different browsers and what works or not. I've found that it's easier just to position one thing at a time and then check my work in the different browsers to make sure everythings alright before proceeding on to the next step.Anyway, I just stumbled upon an article which kind of adressed that concern, but I'd like to get some feedback on it from some of the professionals on this board. He suggested that because of the different margins and padding that different browsers display, you insert the following css:*{margin: 0;padding: 0}My question would be is this actually worth doing? Does it save in the overall time it makes to create the site because less problems arise(as everythings more uniform across all browsers), or is this actually a bad technique because it requires more coding to to specify padding/margins for whatever div, element that needs adjusting. Any thoughts on this would be appreciated.
I always start with that when making a new cascading stylesheet. It's easier to make the page render the same in all browsers, and it saves a lot of filesize doing this than writing {padding:0;margin:0} for every selector and element/id.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...