Problem mit Preg_match
Tom1tk
- php
Hallo zusammen,
was mache ich falsch?? Das Teil soll Shit ausgeben, wenn in name ein üöä oder irgendein Leerzeichendrin vorkommt:
$name="Müll";
if(preg_match("*.[üöä\s]*.*",$name,$Muell)){
print "Shit";
}
Danke Tom1tk
Hallo!
$name="Müll";
if (preg_match("/[üöä ]/",$name)) {
print "Shit";
}
Gruß, Achim