Any ideas?
Code: Select all
preg_match_all("/[a-zA-Z0-9\Ä\ä\Ö\ö\Ü\ü\_\-\.\,\=\(\)]+/"Thanks,
Chris[/list]
Moderator: General Moderators
Code: Select all
preg_match_all("/[a-zA-Z0-9\Ä\ä\Ö\ö\Ü\ü\_\-\.\,\=\(\)]+/"Code: Select all
echo '\\';If your locale is set correctly [:alnum:] should match the whole a-zA-Z0-9äöüÄÖÜß part.http://de2.php.net/reference.pcre.pattern.syntax wrote:Note: Single and double quoted PHP strings have special meaning of backslash. Thus if \ has to be matched with a regular expression \\, then "\\" or '\\\\' must be used in PHP code.
Code: Select all
$pattern = '![[:alnum:]\\\\/.,;+]+!';
$subject = 'ßabcäöÜß098';
preg_match_all($pattern, $subject, $matches);
print_r($matches);Code: Select all
instead ofCode: Select all
, otherwise [:alnum:] becomes []