• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

The regExp Object [3|I]

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.

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

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

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

  • leftContext— Indicates the string just before the most recently matched Regular Expression. New in JavaScript 1.2.

  • rightContext— Indicates the remainder of the string, beyond the most recently matched Regular Expression. New in JavaScript 1.2.

  • $1,..$9— Indicates the last nine substrings in a match; those substrings are enclosed in parentheses. New in JavaScript 1.2.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint