Posts: 487
Name: Mark Stegeman
Location: Netherlands, Europe
|
I'll explain the pattern for you:
/: denotes the start of a pattern, doesn't really matter much now
^: denotes the start of a subject which kinda means the next character can only be on the start of the string, I think
[a-z]: matches a character in the range a-z, but only one
$: denotes the end of a subject which means the last character should be at the end of the string.
What this means in total, is that your pattern tries if your string has one character in the range a-z that's both at the beginning and end of the string.
What you want is something like this:
PHP Code:
$pattern = "/[a-z]*/";
The * makes the last part of the pattern match over and over again until it doesn't match anymore.
__________________
<?php ($helpfull>0)?$talkupation++ : '';?>
|