Skip to content

Instantly share code, notes, and snippets.

@ded
Created February 15, 2011 21:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ded/828279 to your computer and use it in GitHub Desktop.
Save ded/828279 to your computer and use it in GitHub Desktop.
document.domain = 'dustindiaz.com';
function fn () {
document.write = "";
window.top.location = window.self.location;
setTimeout(function() {
document.body.innerHTML = '';
}, 0);
window.self.onload = function(evt) {
document.body.innerHTML = '';
};
}
if (window.top !== window.self) {
try {
if (window.top.location.host) {
// fun times
} else {
fn();
}
} catch (ex) {
fn();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment