I'm playing around with finding and replacing text.
The only problem I'm having is finding a text string, that is not attached to an element with an ID. Otherwise, it would be easy.
I'm trying something like this:
$("*").each(function () {
$(this).html(this.html().replace('Original Text','New Text'));
});
Not working too well.
Anyone run into this before?
Also, if I have several words or phrases to find and replace, how does that affect the speed/processing power of the user's browser? Is it a memory hog?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…