Citat:
Originalno napisao bluesman
Samo stavi modifier /U na kraju:
PHP kôd:
preg_match_all('/\{lang(.*)\}(.*)\{\/lang\}/U', $string, $results);
|
E, kul, radi. Šta radi to U na kraju?
Citat:
This modifier inverts the "greediness" of the quantifiers so that they are not greedy by default, but become greedy if followed by "?". It is not compatible with Perl. It can also be set by a (?U) modifier setting within the pattern or by a question mark behind a quantifier (e.g. .*?).
|
Našao sam. Hvala još jednom.
__________________
Never show weakness, the only pain that matters is the pain you inflict.
Poslednja izmena od godza : 27. 02. 2008. u 23:23.
|