title: How to use the bootstrap's scrollspy function with a non bootstrap navbar
body: <p>this is my first website without a CMS and I am little lost with jQuery. I'm just trying to activate the elements of my fixed navbar depending on the position where the user is. I am building my site with bootstrap and that is the reason I am using the scrollspy function. If anybody can help me doing it in an other way would be great.  I have created a fiddle with the html, css and jquery code 
  <a href="http://jsfiddle.net/T6eXc/17/" rel="nofollow">here</a> I also write you down here the code. Thanks in advance.</p>
  
  <pre><code>&lt;body data-spy="scroll" data-target="#top-menu"&gt;
  &lt;div&gt;
  &lt;ul id="top-menu" style="background: green;"&gt;
  &lt;li&gt;&lt;a class="active" href="#"&gt;Home&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="#about"&gt;About&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="#portfolio"&gt;Portfolio&lt;/a&gt;&lt;/li&gt;
  &lt;/ul&gt;
  &lt;/div&gt;
  &lt;br&gt;&lt;br&gt;
  
  &lt;div id="home"&gt;
  &lt;p&gt;This is home section&lt;/p&gt;
  &lt;/div&gt;
  &lt;div id="about"&gt;
  &lt;p&gt;About&lt;/p&gt;
  &lt;/div&gt;
  &lt;div id="portfolio"&gt;
  &lt;p&gt;This is the portfolio&lt;/p&gt;
  &lt;/div&gt;
  &lt;/body&gt;
  </code></pre>
  
  <p>And the jquery is <a href="https://raw.github.com/twitter/bootstrap/master/js/bootstrap-scrollspy.js" rel="nofollow">here</a></p>