How to get id value using angularjs from this path:
http://localhost:1234/?id=3333#/Plya/Home
Any idea how can I do it?
You can use $location.search() followed by your parameter you want to get:
var paramValue = $location.search().id;
This will only work however if you have set html5mode to true in your config like so:
angular.module("myApp", []).config(function($locationProvider) {
$locationProvider.html5Mode(true);
});
Inject $location into your controller
and then you can use
$location.search().id
e.g.
$scope.id = $location.search().id
HTML5 should be enabled for this to work in your case (thanks Chrillewoodz)
In non-HTML5 mode $location.search() only returns params after the hashtag