function hook_og_membership_insert in Organic groups 7
Same name and namespace in other branches
- 7.2 og.api.php \hook_og_membership_insert()
Responds when a OG membership is inserted.
This hook is invoked after the OG membership is inserted into the database.
Parameters
OgMembership $og_membership: The OG membership that is being inserted.
See also
1 function implements hook_og_membership_insert()
Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.
- og_og_membership_insert in ./
og.module - Implements hook_og_membership_insert().
File
- ./
og.api.php, line 442 - Hooks provided by the Organic groups module.
Code
function hook_og_membership_insert(OgMembership $og_membership) {
db_insert('mytable')
->fields(array(
'id' => entity_id('og_membership', $og_membership),
'extra' => print_r($og_membership, TRUE),
))
->execute();
}