Re: About Preg Match patterns

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

 



Am 02.08.12 06:49, schrieb Tolga:
> hi, i have a question, i dont know what keywords to search, so im
> asking here.
>
> while using preg_match, there are lots of thing that can be written as
> $pattern.
> for example:
> preg_match("/php/i", "PHP is the web scripting language of choice.")
>
> what is the meaning of  /i  ?
case-insensitive
http://de.php.net/manual/de/reference.pcre.pattern.modifiers.php
> or '@^(?:http://)?([^/]+)@i'  there are lots of chars here,
>
> or this: /(?P<name>\w+): (?P<digit>\d+)/
<name> and <digit> are subpattern names
http://de.php.net/manual/de/regexp.reference.subpatterns.php
> /[^\\d\\sa-zA-Z$_]/
> /^[a-zA-Z\p{Cyrillic}0-9\s\-]+$/u    (there is a extra "/u" )
utf-8
http://de.php.net/manual/de/reference.pcre.pattern.modifiers.php
>
> #^http:\/\/(.*)\.(gif|png|jpg)$#i
> #<head>(.*?)<\/head>#si
>
> there is lots and lots of different usage of these.
>
> my question is, where can i find a very detailed information about
> these ? i want and need to know whats what about these.
see http://de.php.net/manual/de/pcre.pattern.php
>
> Thanks,
> tolga.
>


-- 
Marco Behnke
Dipl. Informatiker (FH), SAE Audio Engineer Diploma
Zend Certified Engineer PHP 5.3

Tel.: 0174 / 9722336
e-Mail: marco@xxxxxxxxxx

Softwaretechnik Behnke
Heinrich-Heine-Str. 7D
21218 Seevetal

http://www.behnke.biz


Attachment: signature.asc
Description: OpenPGP digital signature


[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