Author | Message | Time |
---|---|---|
St0rm.iD | http://php-fusebox.sourceforge.net/ Once you get used to it, you'll find that, althoguh PHP still sucks, it's not as bad. | August 7, 2004, 4:24 AM |
St0rm.iD | http://us4.php.net/manual/en/function.strpos.php I love how great PHP is!!!! i have to do if ! (stripos... == false) | August 9, 2004, 10:41 PM |
Maddox | Huh? | August 10, 2004, 8:14 AM |
St0rm.iD | you can't do if (strpos(haystack, needle)) you need to do if (! (strpos(haystack, needle) == false)) | August 10, 2004, 4:28 PM |
Maddox | It works for me under PHP 4.3.8 and 5.0.0. | August 11, 2004, 4:04 AM |
St0rm.iD | Doesn't for me under 4.3 | August 12, 2004, 2:37 AM |
Maddox | Try upgrading? 4.3.9RC1 was just released today. | August 12, 2004, 4:48 AM |
St0rm.iD | Alas, I cannot, for I am stuck with what my clients hosting has. | August 12, 2004, 2:47 PM |
Undeference | [quote author=$t0rm link=board=22;threadid=8061;start=0#msg74899 date=1092155309] you can't do if (strpos(haystack, needle)) you need to do if (! (strpos(haystack, needle) == false)) [/quote] Try[code]if (strpos (haystack, needle) === false)[/code] 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][/quote] | August 22, 2004, 11:40 PM |
St0rm.iD | I'd be using Python or CF, except hosting situation has forced PHP upon me. | August 23, 2004, 3:34 PM |