Page 1 of 1

A little Menu Help; Howto distribute the menu items evenly

Posted: Tue Jan 16, 2007 6:58 am
by jdwork
Hello CMS:

  You have wicked product!  ;D Exactly what I need.  I have Ubuntu 6.06 LAMP with CMS Maui.  Everything worked out of the box, zero headaches, and what a beautiful install script. I am using the template CSSMenu Top + 2 Columns with Layout: Top Menu + 2 Columns & Navigation: CSSMenu Horizontal.

  I am redoing a Montessori Preschools website and changing as little as possible from the default templates to stay compatible with IE users and not mess anything up (using KISS principle).

To my question:

I would like to center the elements of my navigation bar leaving equal space before and after the first and last elements
or equally acceptable
I would like to evenly distribute the elements of my navigation bar leaving no space before and  after the first and last element.

Any comments or suggestions are appreciated.

Thankyou,
Jesper

Re: A little Menu Help; Howto distribute the menu items evenly

Posted: Fri Feb 02, 2007 10:33 pm
by casidougal
I've been waiting to see if someone has a good solution for this. This same issue has been frustrating me...I can cheat by playing with the width attribute e.g.

#menuwrapper {
/*  overflow: hidden;  */
background-color: transparent;
margin-left: auto;
margin-right: auto;
z-index: 500;
position: relative;
margin-bottom: -2px;
width: 95%;
}

Re: A little Menu Help; Howto distribute the menu items evenly

Posted: Sat Feb 03, 2007 3:02 am
by Dr.CSS
If you had a link I could whip something up for it, I've got a few on my site but would not be able to tell you your solution w/o seeing it, usually margin: 0px auto; works but where to put it is the ? menu, menuwrapper, wrapper? depends...

Re: A little Menu Help; Howto distribute the menu items evenly

Posted: Sat Feb 03, 2007 11:11 pm
by casidougal
I know I'm not the original poster of this topic but I have a couple examples...

http://treasurevalleyhearing.com/

http://richardsteeledds.com/&nbsp; <-- on this one I used my "cheat" to get it close to being centered.

Re: A little Menu Help; Howto distribute the menu items evenly

Posted: Sun Feb 04, 2007 12:57 am
by heatherfeuer
Elements can be centered using CSS by setting a margin value of '0 auto'.

Re: A little Menu Help; Howto distribute the menu items evenly

Posted: Sun Feb 04, 2007 3:48 am
by casidougal
#menuwrapper {
/*  overflow: hidden;  */
background-color: transparent;
margin: 0px auto;
}

Doesn't center my menu...did I get something wrong?

Re: A little Menu Help; Howto distribute the menu items evenly

Posted: Sun Feb 04, 2007 3:58 am
by Dr.CSS
If you don't make the menuwrapper a certain width it will go 100% on it's own so you need to make it less than the page or div it's in to see any shift, notice casidougal has 95% width in his...