[tpm] quicky regex question

Viktor Pavlenko vvp at cogeco.ca
Wed Sep 22 11:49:29 PDT 2010


>>>>> "EJ" == Emil Janev <ejanev at gmail.com> writes:

    EJ> Hi Fulko,
    EJ> I tried this one, and I think it gives the same result:

    EJ> 44.

    EJ> If it was working for you, was it maybe:

    EJ> /^((\d*\.){$n})/

    EJ> This one gives:

    EJ> 00.99.88.77.66.55.44.

This won't include the traling dot and won't populate $2:

/^((?:\.?\d*){$n})/

-- 
Viktor



More information about the toronto-pm mailing list