title: How to use current url params in angular controller
body: <p>I have a dynamic value params in url and I want to get it and use in controller when onload
  But I have no idea how to deal with <code>$route.current.params</code></p>
  
  <p>Let say I have this route provider</p>
  
  <pre><code>$routeProvider.when('foo/:bar', {templateUrl: 'template.html'};
  </code></pre>
  
  <p>Then in my controller</p>
  
  <pre><code>app.controller('mapCtrl', function($scope, $route, $routeParams) {
  
    var param = $route.current.params.bar;
    console.log(param);
  
  });
  </code></pre>
  
  <p>If user access <code>foo/abcdefg</code> suppose should show abcdefg in console but I got error.
  'Cannot read property 'params' of undefined'</p>