RE: [PHP] IF statement question...
| From: | Jay Blanchard | Date: | Wed, 19 May 2004 15:42:01 +0000 |
| Subject: | RE: [PHP] IF statement question... | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-186541@lists.php.net to get a copy of this message | ||
[snip]
strpos() : 0.18918436765671
preg_match() : 0.26665662288666
[/snip]
1/3rd of a second slower....interesting. You know what though, my
original assertion is correct....almost any of the regex functions will
work.
Tristan, why not convert the string to an array and then use in_array()?
John, can you add the array speed test to your script? I'd like to know
how that stacks up too.