title: angular ui routing - avoid hashbang mode. ie9
body: <p>I'm trying to get html5mode, angular ui routing working in  IE9</p>
  
  <pre><code>if (window.history &amp;&amp; window.history.pushState) {
    $locationProvider.html5Mode(true);
  } else {
      console.log('IE9');
      window.location.hash = '/';  // IE 9 FIX            
      $locationProvider.html5Mode(true);
  }
  
  $urlRouterProvider.otherwise("/");
  
  $stateProvider
    .state('placeholder', {
        url: "/path/:myId",
        templateUrl: '../path.html
        controller: 'ResultCtrl'
     }
   );
  </code></pre>
  
  <p>instead of index/path/myid i still get index/#/index/myid which then takes me to index since the browser ignores the hash tag and everything after it. (works in firefox, chrome, edge, IE11-10(browsers supporting html5mode / api history))</p>