Home > Web Front-end > JS Tutorial > body text

Rewriting window.location and determining whether location has been rewritten_javascript skills

WBOY
Release: 2016-05-16 16:37:18
Original
1645 people have browsed it

Window.lcoation can be rewritten without redirection under IE. The specific method is: var location = {}, and then the specific attributes can be rewritten. This will bring certain risks to determine the location through js.
How to determine whether location has been rewritten? After struggling all afternoon, I came up with a method:

(location==document.location&&location instanceof Location)
Copy after login

This method is only used for IE.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template