What is the purpose of the window.location object in JavaScript?
A
Get the URL and redirect
B
Get the location of the cursor
C
Get the path to the next page
D
Get the location & path of the next page
Correct Answer: Get the URL and redirect
The window.location object can be used to get the current page address (URL) and to redirect the browser to a new page. The parameter location specifies the agent location, speed and browser to use for the test, formatted as location.browser:location.