I have some text data that I need to replace some capitalized escaped sequences with lower case. I have the regular expression that finds the matches, but trying to use it with replace is causing some trouble. Basically I need to match items like \N , %S or %D and replace them with \n %s or %d respectively. If it was just these 3, it would be no problem to use StringReplace(), but there are more. Local $line = "This is one line \Nfor of %S\t isn't that great? There are %03d more lines left
The problem is that the back-reference is only evaluated in the RegExp function. Using an example: StringRegExpReplace('Hello', '(.*)', StringLower('\0')) StringLower only receives '\0', so performs a case lowering operation on that string (which is irrelevant for those characters of course) and returns it. StringRegExpReplace then receives '\0' from StringLower, and StringRegExpReplace turns it into 'Hello'. At the moment, there is no way to dynamically alter the data In PHP there is a functi