function _invite_substitutions in Invite 5
Same name and namespace in other branches
- 5.2 invite.module \_invite_substitutions()
- 6.2 invite.module \_invite_substitutions()
Create an invite object with reasonable default values for use in token replacements.
Parameters
$args: Associative array of additional arguments to merge into the invite object.
Return value
The invite object.
2 calls to _invite_substitutions()
- invite_form_submit in ./
invite.module - Forms API callback; processes the incoming form data.
- _invite_token_types in ./
invite.module - Provide token types for use in invite message replacements.
File
- ./
invite.module, line 1370 - Allows your users to send and track invitations to join your site.
Code
function _invite_substitutions($args = array()) {
global $user;
$defaults = array(
'inviter' => $user,
'email' => '--recipient-email--',
'code' => '--invite-code--',
'data' => array(
'subject' => NULL,
'message' => NULL,
),
);
return (object) array_merge($defaults, $args);
}