can someone explain to me why this function doesn't replace "<![CDATA[" in the string s ?
Code:
public static function trim(s:String):String {
s = s.replace(/<![CDATA[/g, "");
s = s.replace(/<![CDATA[/g, "");
s = s.replace(/]]>/g, "");
s = s.replace(/]]>/g, "");
s = s.replace(/^([\s|\t|\n]+)?(.*)([\s|\t|\n]+)?$/gm, "$2");
return s;
}
I'm kind of out of ideas...