Last active
July 2, 2024 02:41
-
-
Save Macrofig/380a56c43024ccee378b80dc2b50a425 to your computer and use it in GitHub Desktop.
Frame testing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>Frame Same Origin test</title> | |
</head> | |
<body> | |
<h1>This is an iframe!</h1> | |
<script type="text/javascript"> | |
(function () { | |
console.log('FRAME', document.domain, window.location.origin) | |
console.log('TOP', window.top.domain, window.top.location.origin) | |
console.log('TOP TITLE', window.top.document.querySelector('.title').textContent); | |
})() | |
</script> | |
</body> | |
</html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>Frame Same Origin test</title> | |
</head> | |
<body> | |
<h1 class="title">Frame Same Origin Test</h1> | |
<iframe src="https://www.juanorozco.com" height="400" width="400"></iframe> | |
<iframe src="https://html-preview.github.io/?url=https://gist.githubusercontent.com/Macrofig/380a56c43024ccee378b80dc2b50a425/raw/3ccfc0faaf0b3984b4015c6c6e2b93ac6ddefe07/frame-test-frame.html" height="400" width="400"></iframe> | |
<iframe src="/?url=https://gist.githubusercontent.com/Macrofig/380a56c43024ccee378b80dc2b50a425/raw/3ccfc0faaf0b3984b4015c6c6e2b93ac6ddefe07/frame-test-frame.html" height="400" width="400"></iframe> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment