The regExp Object [3|I]

The regExp object is relevant to searching for regular expressions. Its properties are set before or after a search is performed. They don't generally exercise control over the search itself, but instead articulate a series of values that can be accessed throughout the search.

Properties

  • input— The string against which a regular expression is matched. New in JavaScript 1.2 and later.

  • multiline [true, false]— Sets whether the search continues beyond line breaks on multiple lines (true) or not (false). New in JavaScript 1.2 and later.

  • lastMatch— Indicates the characters last matched. New in JavaScript 1.2 and later.

  • lastParen— Indicates the last matched string that appeared in parentheses. New in JavaScript 1.2 and later.

  • leftContext— ...

Get Platinum Edition Using XHTML™, XML, and Java™ 2 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.