View Full Version : replace()
How do you use string.replace()? The concept seems simple enough, but I don't understand the $$4\'t\7 type stuff used in the arguements. Is it supposed to be a string? What does it represent and/or do? :confused:
12-27-2004, 07:15 PM
Well to replace I think you can do something like this -
document.body.innerHTML=document.body.innerHTML.replace("1st String","2nd String");
12-27-2004, 08:06 PM
those funky things is a regular expression, it is easy to understand once you know what it means.
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.