diff options
Diffstat (limited to 'mod/twitter')
-rw-r--r-- | mod/twitter/languages/en.php | 40 | ||||
-rw-r--r-- | mod/twitter/start.php | 30 |
2 files changed, 24 insertions, 46 deletions
diff --git a/mod/twitter/languages/en.php b/mod/twitter/languages/en.php index 5e9fcd92b..29700744a 100644 --- a/mod/twitter/languages/en.php +++ b/mod/twitter/languages/en.php @@ -1,30 +1,16 @@ <?php +/** + * Twitter widget language file + */ - $english = array( - - /** - * twitter widget details - */ - - - 'twitter:username' => 'Enter your twitter username.', - 'twitter:num' => 'The number of tweets to show.', - 'twitter:visit' => 'visit my twitter', - 'twitter:notset' => 'This Twitter widget is not yet set to go. To display your latest tweets, click on - edit - and fill in your details', - - - /** - * twitter widget river - **/ - - //generic terms to use - 'twitter:river:created' => "%s added the twitter widget.", - 'twitter:river:updated' => "%s updated their twitter widget.", - 'twitter:river:delete' => "%s removed their twitter widget.", - - - ); - - add_translation("en",$english); +$english = array( -?>
\ No newline at end of file + 'twitter:title' => 'Twitter', + 'twitter:info' => 'Display your latest tweets', + 'twitter:username' => 'Enter your twitter username.', + 'twitter:num' => 'The number of tweets to show.', + 'twitter:visit' => 'visit my twitter', + 'twitter:notset' => 'This Twitter widget is not yet set to go. To display your latest tweets, click on - edit - and fill in your details', +); + +add_translation("en", $english); diff --git a/mod/twitter/start.php b/mod/twitter/start.php index f71af9430..85dde75bd 100644 --- a/mod/twitter/start.php +++ b/mod/twitter/start.php @@ -1,22 +1,14 @@ <?php +/** + * Elgg twitter widget + * This plugin allows users to pull in their twitter feed to display on their profile + * + * @package ElggTwitter + */ - /** - * Elgg twitter widget - * This plugin allows users to pull in their twitter feed to display on their profile - * - * @package ElggTwitter - */ - - function twitter_init() { - - //extend css if style is required - elgg_extend_view('css/screen', 'twitter/css'); - - //add a widget - elgg_register_widget_type('twitter',"Twitter","This is your twitter feed"); - - } - - elgg_register_event_handler('init','system','twitter_init'); +register_elgg_event_handler('init', 'system', 'twitter_init'); -?>
\ No newline at end of file +function twitter_init() { + elgg_extend_view('css/screen', 'twitter/css'); + add_widget_type('twitter', elgg_echo('twitter:title'), elgg_echo('twitter:info')); +} |