It would be useful to make the Mollom data about comments/nodes visible under certain circumstances. For instance if you had spam comments making it onto your site, you could see if they had filled out a CAPTCHA or not, the Mollom session ID, quality rating, and detected languages. This information would be visible to users with an additional permission, something like "view Mollom debugging information" (but shorter).

Attached is an initial screenshot to demonstrate how this would work.

Comments

sun’s picture

Version: 6.x-1.x-dev » 7.x-1.x-dev
Category: task » feature

The major problem with this idea is that we currently do not integrate with the loading or rendering of entities - where entities can mean quite a lot.

For D7, we might want to analyze whether using a pseudo-field could do the trick (similar to taxonomy term fields), but I'm not sure how useful that would be.

In general, I think I wouldn't even want that info all over the place. With regard to #717212: Remove "report to Mollom" links and integrate with entity delete confirmation forms instead, integrating with delete confirmation forms would perhaps make more sense?

sun’s picture

Assigned: dave reid » Unassigned
Status: Active » Needs review
StatusFileSize
new25.88 KB
new4.48 KB

I don't think we want to display this data on regular view. Instead - which makes this task a lot easier - we want to display the data as "debugging info" in the entity edit form but also in the delete confirmation form.

Note: Quickly scribbled code.

mollom-data-info.png

dries’s picture

I think that makes for a great first step. Clever.

We should add 'Profanity' to the list of fields that we track.

We should also mention whether the user had to fill out a CAPTCHA.

+++ mollom.module	2 Aug 2010 17:02:35 -0000
@@ -578,12 +578,30 @@ function mollom_form_alter(&$form, &$for
+  // Users able to bypass Mollom's protection get debugging information on edit
+  // forms.
+  if (isset($protected_forms[$form_id]) && $mollom_form = mollom_form_load($form_id)) {
+    $show_info = user_access('bypass mollom protection');

I found it to be a bit of a surprise to give this to people with the 'bypass mollom protection' setting. I'm not sure that is logical for end-users but it might be good enough.

sun’s picture

I should have mentioned that the fieldset is collapsed by default.

We should add 'Profanity' to the list of fields that we track.

hah. I would have added that, if we would store it. :P The profanity checking still needs a lot of clean-up.

We should also mention whether the user had to fill out a CAPTCHA.

Hm, properly generating and storing that info that won't be simple. Ideally defer to a separate issue.

I found it to be a bit of a surprise to give this to people with the 'bypass mollom protection' setting.

As mentioned, this is quickly puzzled piece of code. In general, I guess it makes sense. However, it would make even more sense to combine this info with a new user permission... which would immediately bring us back to #771594: Add a permission to control access to report form ;-)

Overall, I'm relatively happy with the code already... not so much with the visual representation - although that simple "list" in a fieldset may work as a first implementation. Since in general, Drupal has no standardized notion of outputting debugging information within the regular user interface, any attempt to make this look prettier in Garland won't work at all in other themes. Hence, I already fear we can't really do much more.

sun’s picture

StatusFileSize
new4.16 KB

1) Adding to the comment view content output now.

2) Still need to add {mollom}.sentiment.

sun’s picture

StatusFileSize
new5.33 KB

mmm, added the module update for {mollom}.sentiment now, but I'm not sure whether it is a good idea to add that. You will have to manually reset the schema version of mollom.module in {system} after reverting this patch and/or updating the module on your site. :-|

Status: Needs review » Needs work

The last submitted patch, mollom-DRUPAL-6--1.info.6.patch, failed testing.

sun’s picture

Version: 7.x-1.x-dev » 6.x-1.x-dev
Status: Needs work » Needs review
StatusFileSize
new5.33 KB

Fixed that syntax error. Also, this patch is for D6. But nice to see it also applies to D7 ;)

dries’s picture

+1 for adding it to the comment view output. Having it on the comment edit form is too much of a pain as the data isn't readily available.

dries’s picture

When I apply this patch and go to update.php, I get Fatal error: Only variables can be passed by reference in /sites/all/modules/mollom/mollom.install on line 649

sun’s picture

StatusFileSize
new5.37 KB

mmm... sorry, a D7 signature slipped into that update.

dries’s picture

StatusFileSize
new182.82 KB

I don't think the Javascript-driven fieldsets are the way to go. There must be better ways to present this data. Attached a suggestion.
meta-data.jpg

sun’s picture

StatusFileSize
new4.42 KB

Added a permission check for "bypass mollom protection" and removed the auto-expanding of fieldsets.

Finding an display style that works for all sites is going to be the largest challenge. For example, your suggestion would work for your site, but not for mine, because on my site, the comment links are aligned to the right, instead of to the left.

sun’s picture

StatusFileSize
new4.83 KB

A different visual representation idea.

dries’s picture

Applied the patch on buytaert.net. Testing!

dries’s picture

StatusFileSize
new247.83 KB

Here is how it looks on my site. Much better than the previous version but could still use more design work. The current visual design is good enough for testing/evaluation.
meta-data-2.jpg

dries’s picture

StatusFileSize
new218.14 KB

Actually, all of the sudden the Javascript started working. I kinda like how it works, and I think this might be something that we want to keep. Here is some additional feedback.

meta-data-feedback-1.jpg

dries’s picture

Talked to the Economist today and they'd like to have this feature for their moderators. When looking at a comment, they'd like to better understand when a CAPTCHA was required. This confirms that there is a real use case for this patch.

I have been using this patch on my site for about 1 week now. Here is my feedback to date:

  1. It has been very helpful for me. I really like this functionality, but then, I might not be the average user. I'm watching Mollom's behavior and decisions like a hawk.
  2. It's a bit annoying to have the pop-up when I hover over the comment -- it often gets in the way of reading the comment. It would be nicer if it only popped up when I hovered over a small Mollom-icon or something. It is a bit intrusive right now.
  3. The CSS is still a bit fubar on my site -- as you can see from #17, there is background. The box is (partially) transparent.
  4. When it says 'unsure', it would be better to say 'captcha' or something.
  5. When a comment was not filtered by Mollom (e.g. because of a server outage or network error), it would be nice to share that as well.
dries’s picture

StatusFileSize
new310.27 KB

Lots of testing with the new backend let me to this request. See attached image.

feedback.jpg