iframe_tester
Version:
A simple way to verify if a user's provided link can be embedded in an iframe.
24 lines (19 loc) • 457 B
HTML
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Iframe Tester</title>
<script src="iframe_tester.js"></script>
</head>
<body>
<script>
//simply test for an iframe
IframeTester.test("http://reddit.com")
//catch an iframe_failed event
document.addEventListener('iframe_failed', function(){
console.log("iframe failed");
})
//promise based response in the futur
</script>
</body>
</html>