blob: 3c277f078ff946d6ed9dd87ea20ae9a4b4ded114 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>focus() before iframe loaded same site</title>
</head>
<body>
<script>
window.onload = function() {
parent.postMessage("onload", "*");
}
document.body.onfocus = function() {
parent.postMessage("onfocus", "*");
}
</script>
</body>
</html>
|