$window.location.origin
returns the wrong value on IE.
The origin property returns the protocol, hostname and port number of a URL.
Example
url: http://localhost:8080/products/search
Chrome:
$window.location.origin
returns http://localhost:8080
IE:
$window.location.origin
returns http://localhost:8080/products/search
How can I have the right value on IE?
$window
is the same aswindow
but provided by Angular. docs.angularjs.org/api/ng/service/$window – Tom Robinson Feb 2 '17 at 16:30