Is there a way for me to find out if the URL in my iframe has been changed, ie, the user has navigated somewhere? Thanks.
相关问题
- Is there a limit to how many levels you can nest i
- How to toggle on Order in ReactJS
- void before promise syntax
- Keeping track of variable instances
- Can php detect if javascript is on or not?
This will trigger your function just before navigating to another page on iframe.
This behaves weird on somebrowsers though.
A similar question over here has some answers that should help you out. If you keep track of where the iframe starts, you can then use the methods in that link to see if it has changed.