[wp-hackers] mollom feedback (was: Spam plugin (was:Deprecated functions and files))

Ozh ozh at planetozh.com
Mon Aug 25 13:45:59 GMT 2008


>So far, I've been developing this plugin since april. It's currently in
>public beta (version 0.6.0) Maybe you should give it a try. I'm keen to
>receive feedback!

What, what? Someone asked for nosy and snoopy unauthoritive comments? 
Sounds like a job for me!

A few comments & suggestions:

- you got the translation thing wrong. It's not _e('string'), it's 
_e('string', 'domain') after you've load_plugin_textdomain('domain', 
$path_to_mo_file)

- I personally hate when plugins add 15 rows in wp_options when one is 
enough. Instead of add_option('mollom_this',$molthis) and 
add_option('mollom_that',$molthat), why not 
add_option(array('mollom_this'=>$molthis,'mollom_that'=>$molthat))? Much 
cleaner on the DB.
More on that: <
http://striderweb.com/nerdaphernalia/2008/07/consolidate-options-with-arrays/>

- upon activation edit-comments.php?page=mollommanage spits "Warning: 
Division by zero on line 317" like mad.

- I don't see the point of the subpage under "Plugins" (with the same 
division by zero mayhem, obviously)

- the default message when a message is refused for lack of configuration 
should not be "You haven't configured Mollom yet! Per the website's 
policy. We could not process your comment.", it should be something like 
"The site admin blabla and your comment blabla". Potentially less 
confusing for commenters who might think "wtf i didn't configure what??"

- I'm not sure the "remove settings upon deactivation" thing is a good 
idea: deactivation != uninstall, and deactivation happens a lot (auto 
updating the plugin, deactivating plugins prior to upgrading WP, etc...). 
As this option is on by default, this is going to confuse & upset a few 
who'll lost everything quite often.
I'd suggest a manual "Remove everything from DB" button that would be 
pressed when the user wants to uninstall, as well as some complying to the 
upcoming 2.7 uninstall feature.
More on that: 
<http://www.santosj.name/general/wordpress-27-plugin-uninstall-methods/>

- Since you have a cool logo & favicon, I'd suggest adding something like:
add_filter('ozh_adminmenu_icon', 'mollom_icon')
function mollom_icon($hook) {
if ($hook == 'mollommanage' || $hook == 'mollom-key-config')
        return $url_to_local_copy_of_favicon.png;
return $hook;
}
That would be very cute with the awesomely awesome Ozh' Admin Drop Down 
Menu ;)
More on that: <
http://planetozh.com/blog/2008/08/admin-drop-down-menu-more-goodness-an-api/>

- I don't get why anti spam plugins insist on creating their own table. Or 
is WP missing a comments_meta table?
Is there nothing you can do with columns 'comment_karma' which is unused 
AFAIK or 'comment_approved', like storing custom values like 
'mollom_unsure' ?
There's no deep thinking behind this comment, I admit it, but I find it 
strange that every plugin needs a table where Akismet doesnt.

- I'd split the plugin in various files and conditionally include them: 
nothing at all should load when someone is viewing a public page, the 
require('class-IXR.php') should occur only when a comment has been 
submitted, the whole captcha stuff should load only if a captcha is 
needed, etc...

- Similarly but more importantly to me, most of the plugin should not load 
"if (is_admin())": unless you consider that a blog owner is a potential 
spammer for their own blog, your plugin will eventually conflict with 
plugins that allow them to reply to comments from within the admin 
interface.

All in all and despite my rather numerous comments, this is a plugin I 
like. Much much much muuuuch cleaner than Defensio who, regardless of how 
efficient it is, is really messy. I'm going to give mollom a try (when you 
group all the options into a single DB entry, that is :)

Cheers,

Ozh
-- 
http://planetozh.com/




More information about the wp-hackers mailing list