Skip to content

Instantly share code, notes, and snippets.

@alivedise
Forked from timdream/index.html
Created June 15, 2012 08:58
Show Gist options
  • Save alivedise/2935507 to your computer and use it in GitHub Desktop.
Save alivedise/2935507 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html manifest="manifest.appcache">
<head>
<meta charset="utf-8">
<meta http-equiv="pragma" content="no-cache">
<!-- System -->
<script>
</script>
</head>
<body>
Hi!!!
<iframe id="frame" mozbrowser src="data:text/html,<button onclick=alert('hi')>press me!</button>">
</iframe>
<script>
window.onload = function () {
document.getElementById('frame').addEventListener(
'mozbrowsershowmodalprompt',
function (evt) {
dump('==== got it!!');
evt.preventDefault();
}
);
};
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment