function voting_service_set_vote in MediaFront 6.2
Same name and namespace in other branches
- 6 services/voting_service/voting_service.module \voting_service_set_vote()
1 string reference to 'voting_service_set_vote'
- voting_service_service in services/
voting_service/ voting_service.module - Implementation of hook_service()
File
- services/
voting_service/ voting_service.module, line 165
Code
function voting_service_set_vote($content_type, $content_id, $vote_value, $tag = "vote") {
$vote['content_type'] = $content_type;
$vote['content_id'] = $content_id;
$vote['value'] = $vote_value;
$vote['tag'] = $tag;
votingapi_set_votes($vote);
votingapi_recalculate_results($content_type, $content_id, TRUE);
return voting_service_get_vote($content_type, $content_id, $tag);
}