Re: Regular Expression

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: McKirahan (News_at_McKirahan.com)
Date: 10/08/04

  • Next message: Brian Staff: "Re: IE Auto-Caches Even With META Expiration Tags"
    Date: Fri, 08 Oct 2004 19:31:28 GMT
    
    

    "Craig" <Craig@discussions.microsoft.com> wrote in message
    news:B5587F23-4375-4861-A63D-279DF2007723@microsoft.com...
    > Many thanks, where did "g" come from?

    [snip]

    >From the documentation :-)

    Description
    Contains a regular expression pattern.

    Syntax 1
    var regularexpression = /pattern/[switch]

    Syntax 2
    var regularexpression = new RegExp("pattern",["switch"])

    The regular expression object syntax has these parts:

    pattern Required. The regular expression pattern to use.

    If you use Syntax 1, delimit the pattern by "/" characters.

    If you use Syntax 2, enclose the pattern in quotation marks.

    switch Optional. Enclose switch in quotation marks if you use Syntax 2.

    Available switches are:
        i (ignore case)
        g (global search for all occurrences of pattern)
        gi (global search, ignore case)


  • Next message: Brian Staff: "Re: IE Auto-Caches Even With META Expiration Tags"

    Relevant Pages

    • Re: Feature request: String-inferred names
      ... especially since all the proposed syntax are ugly (the most acceptable ... When I first started seeing @ show up in Python code, ... the EXACT syntax of the ... The pattern manifested itself ...
      (comp.lang.python)
    • Re: Feature request: String-inferred names
      ... especially since all the proposed syntax are ugly (the most acceptable ... When I first started seeing @ show up in Python code, ... the EXACT syntax of the ... The pattern manifested itself ...
      (comp.lang.python)
    • Re: a SED need
      ... > every syntax I've tried has not worked. ... character is used for regular expression rather than a possible RE ... The match regular expression is repeated in gsub ... Therefore the next match-all pattern ...
      (freebsd-questions)
    • Re: Regular Expression
      ... Contains a regular expression pattern. ... If you use Syntax 1, delimit the pattern by "/" characters. ... Enclose switch in quotation marks if you use Syntax 2. ...
      (microsoft.public.scripting.jscript)
    • Re: please recommend book or web page on beginners lambda calculus
      ... because I can't recall the notation, precedence, etc. ... the syntax used in those ... slides I have never seen before. ... need to distinguish between a pattern parameter (match the pattern this ...
      (comp.lang.functional)