Re: Re: Regular Expression Backreference in subpattern.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Sorry The previous code was wrong,
Its the correct version,

$x = "a b;c d;e f;";
preg_match('/(?P<keys>\w) (?P<values>\w)/',$x,$m);
print_r($m);

Now I am using backrefrence \1 in in ?P option like (?P<\1>\d+).

and I got the error.

-- 

Blog: http://talk.cmyweb.net/
Follow me: http://twitter.com/shiplu

Stop Top Posting.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux