membersound
membersound

Reputation: 86925

How to read the url query parameters in angularjs?

I'm creating a simple angularjs app and want to read the query parameters of the url mypath.com/test.html?param1=test.

Question: how can I read and modify the parameters list?

$location.search() does not return any results here.

Upvotes: 0

Views: 65

Answers (1)

Coder002
Coder002

Reputation: 275

I think you must activate the html5Mode before calling : $location.search()

$locationProvider.html5Mode(true);

Upvotes: 1

Related Questions