Support » Fixing WordPress » trying to add external links to navbar

  • Resolved nharding99



    My first WP site is going quite well, I have adapted the mahusay theme. One thing I’m trying to do is to hardcode some menu options in the main navbar so that this integrates with the rest of the non WP pages.

    I have found the code section that looks like it will do the trick, in a file called header.php I have added some list items intended to link to “Home”, “About Us” etc:

    <div id="navmenu">
                        <li><a href="">Home&nbsp;&nbsp;</a></li>
                        <li><a href="">&nbsp;&nbsp;About Us&nbsp;&nbsp;</a></li>
                        <li><a href="">&nbsp;&nbsp;Portfolio&nbsp;&nbsp;</a></li>
    					<li<?php echo (is_home() ? ' class="current_page_item"': '')?>><a href="<?php echo get_option('home'); ?>/"><span><span>Blog</span></span></a></li>
                        <li><a href="">&nbsp;&nbsp;Testimonials&nbsp;&nbsp;</a></li>
                        <li><a href="">&nbsp;&nbsp;Contact Us&nbsp;&nbsp;</a></li>
                        <?php themefunction_list_pages(); ?>

    I’m expecting those external hrefs to work but they silently fail and when I hover over them they show up as links to the current blog home page, the current page, i.e. rather than e.g. for my main home page.

    Is there a way to make this work?

    Blogsite is at:

    Thanks in advance for any advice

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘trying to add external links to navbar’ is closed to new replies.