WordPress.org

Ready to get started?Download WordPress

Forums

How to link the of the wp_nav_menu (2 posts)

  1. Matt
    Member
    Posted 10 months ago #

    My apologies if the title is confusing. I'm trying to edit a theme such that the <a>is outside the <li> in the Main menu, so that I can make each list item look like a button that can be clicked even when the cursor isn't over the text.

    Much appreciated!

    [Please post markup between backticks or use the code button.]

  2. esmi
    Forum Moderator
    Posted 10 months ago #

    I'm trying to edit a theme such that the is outside the

  3. in the Main menu
  4. Short answer: you can't. That would be very badly broken markup. Inline tags (eg <a>) cannot enclose block-level tags (eg <li>). You should be able to achieve a button effect using pure CSS.

Reply

You must log in to post.

About this Topic