I am confused as to the difference between window.location and location.href. Both appear to be acting in the same way.
window.location
location.href
What is the differe
location.href property returns the entire URL of the current page.
window.location property represents the currect location of the window object, if you change this you will get redirected.