bbala Posted October 1, 2010 Share Posted October 1, 2010 Nothing about back references of regular expressions are mentioned at javascript Regex tutorial or reference.http://www.w3schools.com/js/js_obj_regexp.asphttp://www.w3schools.com/jsref/jsref_obj_regexp.aspAre they not w3 standards? Link to comment Share on other sites More sharing options...
Synook Posted October 1, 2010 Share Posted October 1, 2010 JavaScript does not support lookbehinds, and thus no backreferences can be captured. It does support lookaheads, however.[1]As for standardisation, the W3C didn't create regular expressions (neither did they create JavaScript) - the common Perl dialect of regular expressions is standardised by the Perl developers, and the ECMAScript standard, which JavaScript follows, was written by Ecma International. Link to comment Share on other sites More sharing options...
jeffman Posted October 1, 2010 Share Posted October 1, 2010 Mozilla says otherwise.The discussion of string.replace adds info about passing functions instead of a replacement string, and how those functions can receive backreferences as arguments. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.