I was reading about an old drupal feature- comment moderation,
http://drupal.org/node/23703

where users could vote on comments and if they are below a certain threshold the comment is folded, but can be javascript opened with a click.

This would be a great feature to hide troll comments, but not delete them altogether, so other users can decide if it truly was a troll/spammer. That way sites wouldn't have joe troll running around hollering- they deleted my posts blah blah.

I was looking into the karma module, but that doesn't quite do what I'm looking for, which is the show/hide javascript feature, comments below -2 (or whatever) are hidden unless clicked by a user.

Comments

justin3’s picture

I've got this all figured out except for one thing, how to pull the vote value for the comment, so if it's below -2 the comment is hidden by default, but the title is there with a show/hide javascript link.

the php is:
if (($vote_result->value) < -2) {...

but $vote_result->value is not correct

I've also tried:
$vote_result
$votingapi->value
$comment->value

and about 20 other variations-- aargh.
can you help out- what is the vote value variable?

thanks :)

frjo’s picture

I'm interested to see the code for this solution, especially if you use jQuery.

If you look at the funktion theme_vote_up_down_points() in vote_up_down.module you can see how to get the voting result. Something like this.

$vote_result = votingapi_get_voting_result('comment', $cid, 'points', variable_get('vote_up_down_tag', 'vote'), 'sum');
chrisroditis’s picture

Any news on this guys? Justin3 did you sort this out? We'd all be grateful for a solution I guess, since karma is not exactly what we'd like it to be

mukhsim’s picture

Nodecomment module is in the works.
Essentially, all comments will be nodes and it will be possible to apply all functionality of nodes to comments. Moderation, sorting and etc of comments will be much easier.

Delf.

ola90@drupal.ru’s picture

I posted my solution (which may be not very elegant, but works) here: http://drupal.org/node/105658

alexandreracine’s picture

Status: Active » Closed (fixed)

Cleaning a little...

4.x versions are not supported anymore.

-You can upgrade
-You can sponsor future developpement of this module (look on the related pages on drupal.org)
-Look at comment #5.

If interesting reopen.