Centered horizontal menu - is it possible?

About the template and stylesheet - and changing the menu
cmb
Posts: 14227
Joined: Tue Jun 21, 2011 11:04 am
Location: Bingen, RLP, DE
Contact:

Re: Centered horizontal menu - is it possible?

Post by cmb » Thu Aug 14, 2014 9:30 pm

Korvell wrote:I'll let the test site stay for a while
Thanks. :)
svasti wrote:I also had the problem of a centered menu and finally got it to work.
The example is here
A fascinating solution! :)
svasti wrote:However, if I understand correctly, this is not automatic but you have to give the class .nave manually?
Probably one could use the :last-child pseudo selector instead of a special class.
svasti wrote:An automatic solution would be interesting for responsive layouts.
I believe there is no pure CSS solution when the menu might span multiple rows; but I might be mistaken. Anyway, some JavaScript (cue: Element.offsetLeft()) could solve the issue.
Christoph M. Becker – Plugins for CMSimple_XH

Korvell
Posts: 98
Joined: Thu May 22, 2008 10:33 pm

Re: Centered horizontal menu - is it possible?

Post by Korvell » Fri Aug 15, 2014 8:31 pm

The last menu item automatically gets the .nave class. I use a sosf-navigation from some older templates - CMSimple-Styles if I remember right...

cmb
Posts: 14227
Joined: Tue Jun 21, 2011 11:04 am
Location: Bingen, RLP, DE
Contact:

Re: Centered horizontal menu - is it possible?

Post by cmb » Fri Aug 15, 2014 9:08 pm

Korvell wrote:The last menu item automatically gets the .nave class. I use a sosf-navigation from some older templates - CMSimple-Styles if I remember right...
Thanks for the clarification. And yes, sosf is made by CMSimple-Styles and included in some of their templates.
Christoph M. Becker – Plugins for CMSimple_XH

Post Reply