WordPress intergration of bootstrap navbar-fixed-top

I’m trying to port my static website to a wordpress based site so I can do blogs and news and RSS feeds easily. I’ve run in to a problem however when using bootstraps navbar-fixed-top plug in. I can’t get it to sit properly, everything is aligned to the far left of the page, the image isn’t showing up and I’ve been messing around all day with it with no results. could someone please help me out?

Here is my wordpress code:

Read More
  <div class="navbar navbar-default navbar-fixed-top">
  <div class="container">
    <div class="navbar-header">
      <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
      </button>
      <a class="navbar-brand" href="#"><img src="img/logo-menu.png" ></a>
    </div>
<nav class="navbar navbar-default navbar-fixed-top">
<?php wp_nav_menu( array( 'theme_location' => 'header-menu', 'container_class' =>   'navbar-collapse collapse', 'items_wrap' => '<ul class="nav navbar-nav">%3$s</ul>' ) ); ?>
</div>
</nav>

And here is the code from my static website:

    <nav class="navbar navbar-default navbar-fixed-top">
  <div class="container">
    <div class="navbar-header">
      <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
      </button>
      <a class="navbar-brand" href="#"><img src="img/logo-menu.png" ></a>
    </div>
    <div class="navbar-collapse collapse">
      <ul class="nav navbar-nav">
        <li class="active"><a href="index.php">Home</a></li>
        <li><a href="#about">About</a></li>
        <li><a href="#projects">Projects</a></li>
        <li><a href="blog.php">Blog</a></li>
        <li><a href="#contact">Contact</a></li>
      </ul>
    </div><!--/.nav-collapse -->
  </div>
</nav>

Related posts

Leave a Reply

1 comment

  1. I figured it out, the following method works for anyone who is stuck in a similar situation here is the code:

      <!-- Fixed navbar -->
    <nav class="navbar navbar-default navbar-fixed-top">
      <div class="container">
        <div class="navbar-header">
          <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </button>
          <a class="navbar-brand" href="#"><img src="img/logo-menu.png" ></a>
        </div>
        <div class="navbar-collapse collapse">
    <?php wp_nav_menu( array( 'theme_location' => 'header-menu', 'container_class' => 'navbar-collapse collapse', 'items_wrap' => ' <div class="navbar-collapse collapse">
          <ul class="nav navbar-nav">%3$s  </ul>
        </div><!--/.nav-collapse -->' ) ); ?></nav>