• ronthewebdev

    (@ronthewebdev)


    I am trying to figure out how to stack navigation menu anchor text.

    For instance, I have a link that displays as:

    Admissions & Offers

    But, I need it to display as:

    Admissions
    &
    Offers

    and be centered.

    I have tried several CSS methods, but nothing seems to work.

    Is there some other way of doing this?

    Thanks

    • This topic was modified 4 years ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not an Developing with WordPress topic
Viewing 1 replies (of 1 total)
  • Moderator bcworkz

    (@bcworkz)

    You usually can add basic HTML to menu item labels, so you could insert HTML line breaks, i.e.
    Admissions<br>&<br>Offers

    Of course the concern is having to manually do so for every label. An ideal CSS solution would do so automatically. The problem with CSS, as you’ve likely discovered, is line feeds are managed by width, not by words. I’m not aware of a way for CSS to know on its own to put a single character like “&” on its own line if it fits in the available width elsewhere.

Viewing 1 replies (of 1 total)

The topic ‘How to stack navigation menu anchor text?’ is closed to new replies.