Skip to:
Content
Pages
Categories
Search
Top
Bottom

Customising html for navigation menu in child theme

  • @nickharambee

    Participant

    Hi,

    I am developing a child theme for the Buddypress default theme. I am wanting to make significant changes to the html for nav menu items. It appears that the function wp_nav_menu generates the nav div html. From having read the info on creating child themes it would seem that the best approach is to create a functions.php file in my child theme directory and then add a new function there, say wp_nav_menu2, and then include this in my header.php. Having looked at the default functions.php file it is not clear to me what I need to copy over to my functions.php from the default version, and where I would add the html for my nav items. I would like the html for each nav item to be in the form:

    <li>
    <div class="box">
    <div class="top"></div><div class="clear">
    <div class="bottom" id="current">
    <a href="index.html">
    <div class="left"></div>
    <div class="center">home</div>
    <div class="right"></div>
    </a>
    </div>
    </div>
    </li>

    Complicated markup I know, but it enables me to construct nav items from various background images.

    Could someone advise me as to how to implement this?

    Thanks,

    Nick

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Customising html for navigation menu in child theme’ is closed to new replies.
Skip to toolbar