[spam-stopper] Bug
Andy Skelton
skeltoac at gmail.com
Wed Sep 21 16:56:49 UTC 2005
code:
$response = explode("\r\n\r\n", $response, 2);
if ( 'true' == $response )
$auto_comment_approved = 'spam';
php manual:
explode
(PHP 3, PHP 4, PHP 5)
explode -- Split a string by string
Description
array explode ( string separator, string string [, int limit] )
Returns an array of strings, each of which is a substring of string
formed by splitting it on boundaries formed by the string separator.
If limit is set, the returned array will contain a maximum of limit
elements with the last element containing the rest of string.
---
An array will never be equal to 'true'. Try testing $response[1].
Andy
On 9/21/05, Matt Mullenweg <m at mullenweg.com> wrote:
> Matt Mullenweg wrote:
> > There seems to be a bug where the web service marks it as spam but it
> > still shows up in WP anyway. I'm going to try to track this down
> > tomorrow, a cursory overview didn't reveal any problems with the plugin.
>
> Okay, I have no idea what changed but $response seems to be an array now
> rather than a string. I'll test this on a few other servers and see
> what's up.
>
> --
> Matt Mullenweg
> http://photomatt.net | http://wordpress.org
> http://pingomatic.com | http://cnet.com
> _______________________________________________
> spam-stopper mailing list
> spam-stopper at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/spam-stopper
>
More information about the spam-stopper
mailing list