Reputation for referring user

5.21K viewsCore
0

Thanks for such great plugin. I want to know how I can add reputation to system when someone refer new user to my site. Under reputation tab what should I add to get user refer reputation for consideration.

Also can I categorize user based on specific month or week having high reputation during specific period.

0

hi, thanks for develop this plugin is the best. But i have a question and is about how can i get the recent comments activity of my published posts along with the activities of the AnsPress.io.

1

Under reputation tab you just have a set of constants that could be used by your code.

Code you want to have is not written yet, you have to write it yourself.

For example here is how handling “new comment added” looks like:

$ap->add_action( 'ap_publish_comment', $this, 'new_comment' );
	public function new_comment($comment) {
		$reputation = ap_reputation_by_event( 'new_comment', true );
		ap_reputation( 'comment', $comment->user_id, $reputation, $comment->comment_ID );
	}

It just looks for that “new_comment” constant in database, then add this constant to reputation.

 

One would indeed expect AnsPress to hook itself to each event listed on Reputation tab, and add it’s value every time this event fires. No idea why it’s not implemented like this already.