Created
June 9, 2009 10:44
-
-
Save vrutberg/126415 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() { | |
function piratify(str) { | |
return str.replace(/pp/gi, "(pp)"); | |
} | |
var tags = ['p','li','h1','h2','h3','h4','h5','h6','td','th']; | |
var texts = []; | |
for(var i = 0; i < tags.length; i++) { | |
texts = document.getElementsByTagName(tags[i]); | |
for(var j = 0; j < texts.length; j++) { | |
texts[j].innerHTML = piratify(texts[j].innerHTML); | |
} | |
} | |
return false; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment