title: How to make div follow when scrolling AngularJS
body: <p>In my AngularJS project i have a search bar on top of the page.when user searched something,result will display below to search bar.user can scroll down on the result.what i'm trying to do is,when user scroll down,search bar should follow.i found <a href="https://jsfiddle.net/Lvwh3box/1/" rel="nofollow noreferrer">JQuery code</a>.but i want it in AngularJS.how can i convert this in to AngularJS or is there another easy solution?</p>
  
  <pre><code>&lt;div id="p_search"&gt;
            &lt;div class="input-group"&gt;
              &lt;input class="form-control input-lg" placeholder="Search Here" ng-model="query.name" /&gt;
              &lt;select class="form-control input-lg" placeholder="All Cetegories" ng-model="query.category"&gt;
                &lt;option ng-repeat="option in categories" value="{{option.id}}"&gt;{{option.category}}&lt;/option&gt;
                  &lt;/select&gt;
              &lt;span class="input-group-btn"&gt;
                &lt;button class="btn btn-purple btn-lg" type="submit" &gt;&lt;i class="fa fa-search"&gt;&lt;/i&gt;&lt;/button&gt;
              &lt;/span&gt;
            &lt;/div&gt;
          &lt;/div&gt;
  </code></pre>
  
  <p>My Controller</p>
  
  <pre><code>myApp.controller('PController', function ($scope, $http, $window, Common, localStorageService) {
  
  });
  </code></pre>