hash([hash]);
This method is getter / setter.
Returns the hash fragment when called without any parameters.
Changes the hash fragment when called with a parameter and returns $location
.
// given url http://example.com/#/some/path?foo=bar&baz=xoxo#hashValue var hash = $location.hash(); // => "hashValue"
Parameters
Param | Type | Details |
---|---|---|
hash (optional) | string number | New hash fragment |
Returns
string |
hash |
Please login to continue.