0 Replies Latest reply on Feb 18, 2011 10:10 AM by peterdoyle

    Regex replace ^

    peterdoyle

      Hi trying to find a way of removing some text from a string where there is a ^ followed by either a number of character.  So I want to remove ^6 or ^h or whatever.  Trying the following:  var colorPattern:RegExp = /^[A-Za-z0-9]/g; match.replace(colorPattern,"");  I have tested the regex in a tester which seemed to work but this just returns match with the original text.  This is my first time using regex so any help would be appreciated.  Cheers Peter