I'm using mollom to catch spam. The normal sitewide contact form is protected by it. But the sitewide contact form within the block isn't protected anymore.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

fuerst’s picture

That can be done by implementing hook_mollom_form_info() as described in mollom/mollom.api.php. I welcome patches for an implementation of it.

boabjohn’s picture

Righto...wish I could patch. Anyone out there with some chops and a casual afternoon? This patch would be really quite useful!

paddy_mul’s picture

subscribing...

scott859’s picture

subscribing

sun’s picture

Title: integrate with mollom » Breaks other modules (e.g., Mollom)
Category: feature » bug
Priority: Normal » Critical
Status: Active » Needs review
FileSize
12.68 KB

Attached patch revamps this module to properly integrate with Form API and do not break other modules that also attach to the contact form.

sun’s picture

Status: Needs review » Reviewed & tested by the community
FileSize
13.8 KB

Attached patch additionally re-implements the removal of disabled categories from the regular site-wide contact form.

I've also updated the comment about D7, since #757154: Base form_id via hook_forms() not taken into account for #validate, #submit, hook_form_FORMID_alter() just landed. Yay! :)

sun’s picture

Still RTBC. :)

fuerst’s picture

Thanks for the patch. Will look into it in the next days. Just overloaded currently..

roborracle’s picture

I tried to merge the patch in to the source files, but kept running in to errors - specifically with this section:

   // Warning if no contact category being set
@@ -231,33 +179,12 @@ function contact_form_blocks_settings() 
     drupal_set_message(t("You need to !link first before being able to set them here.", array('!link' => l("create contact form categories", "admin/build/contact/add"))));
     return array();
   }

I'm not much of a programmer but that made zero sense to me. Also -there is a patch listed for the .info file but I couldn't really tell if there were substantial differences from the original to the patch. If anyone could help I'd be most grateful!

sun’s picture

This patch is against latest code in CVS, which may differ from the code in the official release.

tallsimon’s picture

can this go in to a release please!!! would be really useful as webforms also currently breaks mollom when put in a block

fuerst’s picture

Sorry for taking that long. I commited the patch from #6 (thanks a lot for the huge work!) and created a 6.x-1.x-dev release. Will be available in the next hours at the project page.

sun’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.