Skip to content

Instantly share code, notes, and snippets.

@sandosh
Created March 17, 2011 06:57
Show Gist options
  • Save sandosh/873945 to your computer and use it in GitHub Desktop.
Save sandosh/873945 to your computer and use it in GitHub Desktop.
javascript:(function()%20{var%20something;something%20=%20function()%20{var%20d,%20domain,%20domainSrc,%20html,%20iframe;iframe%20=%20document.createElement(%27iframe%27);iframe.style.width%20=%20%27500px%27;iframe.style.height%20=%20%27400px%27;document.body.appendChild(iframe);try%20{iframe.contentWindow.document.open;}%20catch%20(error)%20{domain%20=%20document.domain;domainSrc%20=%20%22javascript:var%20d=document.open();d.domain=%27%22%20+%20domain%20+%20%22%27;%22;iframe[src]%20=%20domainSrc%20+%20%22void(0);%22;}html%20=%20function()%20{return%20[%27<body%20onload=%22var%20d=document;%20%27,%20%22d.getElementsByTagName(%27head%27)[0].appendChild(d.createElement(%27script%27)).src=%27http://sandosh.info/media2/iframe.js%27;%22,%20%27%22%27,%20%27%27,%20%27></body>%27].join(%27%27);};try%20{d%20=%20iframe.contentWindow.document;d.write(html());return%20d.close();}%20catch%20(error)%20{return%20iframe[src]%20=%20domainSrc%20+%20%27d.write(%22%27%20+%20html().replace(/%22/g,%20%27\\%22%27)%20+%20%27%22);d.close();%27;}};something();}).call(this);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment