humanmade / comment-popularity

Allow visitors to vote on comments
MIT License
25 stars 15 forks source link

Negative comment weight and colouring #87

Closed solhuebner closed 9 years ago

solhuebner commented 9 years ago

Is there a css class so one could indicate how good/bad a comment is with colours? Would be maybe smart? What do you think about that?

But the main issue: I tried add_filter( 'hmn_cp_allow_negative_comment_weight', '_return_true' ); but the comment stays at 0. Is this expected? I thought it can go into -x?

Kind regards

pdewouters commented 9 years ago

Did you try creating a mu-plugin? It doesn't work if you put the code in functions.php, because it's too late in the WordPress load order

solhuebner commented 9 years ago

Ok which file do you recommend to put in?

pdewouters commented 9 years ago

Here's how: http://gregrickaby.com/create-mu-plugin-for-wordpress/

pdewouters commented 9 years ago

For the comment classes, I think you need to look at comment_class(), you can filter the classes. Something like this: http://wordpress.org/support/topic/editing-the-classes-in-comment_class#post-1336912

pdewouters commented 9 years ago

This should work if you just want to use functions.php https://github.com/humanmade/comment-popularity/pull/91#issuecomment-58357917