Jump to content

my CSS navigation has odd left indent...


eyezac

Recommended Posts

I don't claim any skillz in putting this together, i am a css noob. credit goes to Ghettocooler (http://ghettocooler.net/2007/05/31/simple-navigation-with-css-image-replacement/) for his slick image based navigation. My mod included the text as part of the navigation though.

 

Anyway, looking at this navigation menu www.gobigbanners.com/nav2.html

notice the navigation hovering to the right? It isn't the page margins (they are zero) and it also behaves the same once placed into a table.

 

I tried adding "padding:0;" to some of the chunks to see if somehow it was giving me un-asked-for padding, but to no avail.

 

Any thoughts on this?

Link to comment
Share on other sites

Man, you are a genius. No wonder those dudes stole your site.

 

So to help me understand the syntax;

 

"ul#goBigNav" is the 'master' control (for lack of a better description) and its properties will trickle down to the others ("ul#goBigNav li", "ul#goBigNav li a" etc) UNLESS their individual properties are changed. is this correct?

 

in the case of my (half) code, since I left out "ul#goBigNav" it took on some life of its own or some default padding and margin settings, correct?

 

thanks again, really appreciate you taking the time and effort to troubleshoot this for me. I have learned a lot.

Link to comment
Share on other sites

Man, you are a genius. No wonder those dudes stole your site.

 

So to help me understand the syntax;

 

"ul#goBigNav" is the 'master' control (for lack of a better description) and its properties will trickle down to the others ("ul#goBigNav li", "ul#goBigNav li a" etc) UNLESS their individual properties are changed. is this correct?

 

Basically, yes. Keep in mind that some elements have default styles that the browsers apply, so for example, adding "body { padding:0; margin:0 }" to your css won't change all elements inside it to use padding:0 and margin:0. However, if you set a font style or size in your body, that will cascade down.

 

in the case of my (half) code, since I left out "ul#goBigNav" it took on some life of its own or some default padding and margin settings, correct?

 

It just defaulted to the default browser settings, which add padding (or margin, off the top of my head, I can't remember) to the left side.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...