Created
August 29, 2008 22:45
-
-
Save topfunky/8069 to your computer and use it in GitHub Desktop.
This file contains 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
(function(i) {u = navigator.userAgent; e = /*@cc_on!@*/false; st = setTimeout; | |
if(/webkit/i.test(u)){st(function(){dr = document.readyState;if(dr=="loaded"|| | |
dr=="complete"){i();}else{st(arguments.callee,10);}},10);}else if((/mozilla/i. | |
test(u)&&!/(compati)/.test(u))||(/opera/i.test(u))){document.addEventListener( | |
"DOMContentLoaded",i,false);} else if(e){(function(){t=document.createElement( | |
'doc:ready');try{t.doScroll('left');i();t= null;}catch(e){st(arguments.callee, | |
0);}})();}else{window.onload = i;}})(function() { | |
// Stylesheet loaded into HEAD tag directly, but in-line it to avoid | |
// making another HTTP request. | |
var s=document.createElement('style'); | |
document.getElementsByTagName('head')[0].appendChild(s); | |
var css = ""; | |
if(!!window.ActiveXObject) { // ie. | |
document.styleSheets[document.styleSheets.length-1].cssText = css; | |
} else { | |
stylenode = document.createTextNode(css); | |
s.appendChild(stylenode); | |
} | |
badge = document.getElementById("my_div"); | |
if (badge) badge.innerHTML = 'MY HTML'; | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment