1 Reply Latest reply on Aug 2, 2006 7:43 AM by kglad

    programming a find / replace function

    15266
      I know of this code:

      myString = "The quick brown fox jumps over the quick dog";
      myString = myString.split("quick").join("dirty");
      trace(myString);


      The problem with this is that it will instantly replace all found items with the .join word. How can I modify this script or create a new one that will allow me to step through each matched term before I replace each of them?

      Thanks