title: Navigate to HTML page using ng-click
body: <p>I have button that I want it to :</p>
  
  <ol>
  <li><p>Call multiple functions from the controller using <code>ng-click</code>(and I have to call them in HTML)</p></li>
  <li><p>Navigate to another html page placed in "<code>static/page.html</code>"</p></li>
  </ol>
  
  <p><code>onclick</code>, when used to navigate (location.href), is override <code>ng-click</code>! Even when binding all the functions.</p>
  
  <p>Here is the button tag :</p>
  
  <pre><code>&lt;div ng-repeat="object in nc.objects"&gt;
   &lt;button ng-click="fun1(object.id); fun2(object.name);"&gt;
   button
   &lt;/button&gt;
  </code></pre>
  
  <p>
            
           button
           </p>
  
  <p></p>
  
  <pre><code>$scope.fun1 = function (id) {
  
          var url = "/req/"+id;
          var Request = $http.get(url);
          Request.then(function (response) {
              $localStorage.var1  = response.data;
  
          });
  
      }
  
      $scope.fun2 = function (name) {
  
          var url = "/otherReq/"+name;
          var Request = $http.get(url);
          Request.then(function (response) {
              $localStorage.var2  = response.data;
  
          });
  
      }
  </code></pre>
  
  <p>ngRoute</p>
  
  <pre><code>myApp.config(['$routeProvider',
      function($routeProvider) {
          $routeProvider.
  
          when('/page2', {
              templateUrl: 'page2.html' &lt;!-- also tried static/page2.html  but not working --&gt;
          });
  
      }]);
  </code></pre>
  
  <p>in HTML</p>
  
  <pre><code>&lt;button ng-click = "navigate(object.id, object.name, '/page2' )" &gt; &lt;/button&gt;
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/Wo5e6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Wo5e6.png" alt="Folder Structure"></a></p>