Passing dynamic variable from routeprovider to controller
<p>I am trying to pass my dynamic variable from route to controller. I am using following code. However it is not working, It basically possing :slug, not the variable string i want. For example if I am trying to get /pages/web-dev-1 and hope to store web-dev-1 inside :slug and pass to controller, it only passes :slug. </p>

<pre><code>$routeProvider.when('/pages/:slug',{
        templateUrl:'partials/service.php',
        controller: 'oneServiceController',
        params: ':slug'
    }); 
</code></pre>

<p>Any suggestion?</p>