http://php-fusebox.sourceforge.net/
Once you get used to it, you'll find that, althoguh PHP still sucks, it's not as bad.
http://us4.php.net/manual/en/function.strpos.php
I love how great PHP is!!!!
i have to do if ! (stripos... == false)
Huh?
you can't do
if (strpos(haystack, needle))
you need to do
if (! (strpos(haystack, needle) == false))
It works for me under PHP 4.3.8 and 5.0.0.
Doesn't for me under 4.3
Try upgrading? 4.3.9RC1 was just released today.
Alas, I cannot, for I am stuck with what my clients hosting has.
Quote from: $t0rm on August 10, 2004, 11:28 AM
you can't do
if (strpos(haystack, needle))
you need to do
if (! (strpos(haystack, needle) == false))
Try
if (strpos (haystack, needle) === false)
This is why they created the === operator.
But you are right about PHP sucking... use instead preg_match. You might have better luck. Or just use Perl (you will never have the stupid problems).
Quote
I'd be using Python or CF, except hosting situation has forced PHP upon me.