function _twitter_post_default_message in Twitter 7.6
Sets default messages for core entities.
Parameters
string $entity_type: The entity type name.
Return value
A string with a suggested default message for the tweet.
1 call to _twitter_post_default_message()
- twitter_post_field_widget_form in twitter_post/
twitter_post.field.inc - Implements hook_field_widget_form().
File
- twitter_post/
twitter_post.field.inc, line 206 - Field configuration for twitter_post module.
Code
function _twitter_post_default_message($entity_type) {
switch ($entity_type) {
case 'comment':
$message = 'New comment: [comment:url:absolute]';
break;
case 'node':
$message = 'New post: [node:title] [node:url:absolute]';
break;
case 'user':
$message = 'New user: [current-user:name]';
break;
default:
$message = 'Select replacement patterns below to build your tweet.';
break;
}
return $message;
}