If the drupalit was using module_invoke_all('drupalit') when a vote is casted, other module could be notified of a vote and react to it.
Other modules would simply have to implement a hook_drupalit($nid, $data) function to do whatever they want when a user votes.
For example, the userpoints_contrib module could have a module that give points to users which votes on a node using drupalit module. I wrote such module but I cannot contribute it back unless the drupalit module uses a hook.
Here's my proposed solution (attached).
What do you think?
| Comment | File | Size | Author |
|---|---|---|---|
| hook_drupalit.patch | 726 bytes | roychri |
Comments
Comment #1
ergelo commentedi would be very interested in this functionality, especially if it would allow integration with the actions module.. unfortunately i rather not test as my site is live already and wouldn't want to interfere with current functionality.. will give it a go as soon as i have time to create an empty setup.. plz let me know how its going
b.