]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - plugins/Facebook/facebookinvite.php
Ticket #3022: fix formatting output for ApiAction::clientError and ApiAction::serverE...
[quix0rs-gnu-social.git] / plugins / Facebook / facebookinvite.php
index 3380b4c857d4de1f365d5534cf80fbc76ae5c71e..a50eace12f7a13796c0289850dc2abe5dc72c5de 100644 (file)
@@ -25,7 +25,6 @@ require_once INSTALLDIR . '/plugins/Facebook/facebookaction.php';
 
 class FacebookinviteAction extends FacebookAction
 {
-
     function handle($args)
     {
         parent::handle($args);
@@ -41,7 +40,6 @@ class FacebookinviteAction extends FacebookAction
      *
      * @return void
      */
-
     function showForm($error=null)
     {
         $this->error = $error;
@@ -56,7 +54,6 @@ class FacebookinviteAction extends FacebookAction
      *
      * @return void
      */
-
     function showContent()
     {
         if ($this->arg('ids')) {
@@ -68,10 +65,11 @@ class FacebookinviteAction extends FacebookAction
 
     function showSuccessContent()
     {
-
-        $this->element('h2', null, sprintf(_('Thanks for inviting your friends to use %s'),
+        // TRANS: %s is the name of the site.
+        $this->element('h2', null, sprintf(_m('Thanks for inviting your friends to use %s.'),
             common_config('site', 'name')));
-        $this->element('p', null, _('Invitations have been sent to the following users:'));
+        // TRANS: Followed by an unordered list with invited friends.
+        $this->element('p', null, _m('Invitations have been sent to the following users:'));
 
         $friend_ids = $_POST['ids']; // XXX: Hmm... is this the best way to access the list?
 
@@ -85,13 +83,12 @@ class FacebookinviteAction extends FacebookAction
             $this->elementEnd('li');
         }
 
-        $this->elementEnd("ul");
-
+        $this->elementEnd('ul');
     }
 
     function showFormContent()
     {
-        $content = sprintf(_('You have been invited to %s'), common_config('site', 'name')) .
+        $content = sprintf(_m('You have been invited to %s'), common_config('site', 'name')) .
             htmlentities('<fb:req-choice url="' . $this->app_uri . '" label="Add"/>');
 
         $this->elementStart('fb:request-form', array('action' => 'invite.php',
@@ -100,7 +97,8 @@ class FacebookinviteAction extends FacebookAction
                                                       'type' => common_config('site', 'name'),
                                                       'content' => $content));
         $this->hidden('invite', 'true');
-        $actiontext = sprintf(_('Invite your friends to use %s'), common_config('site', 'name'));
+        // TRANS: %s is the name of the site.
+        $actiontext = sprintf(_m('Invite your friends to use %s'), common_config('site', 'name'));
 
         $multi_params = array('showborder' => 'false');
         $multi_params['actiontext'] = $actiontext;
@@ -122,7 +120,8 @@ class FacebookinviteAction extends FacebookAction
 
         if ($exclude_ids) {
 
-            $this->element('h2', null, sprintf(_('Friends already using %s:'),
+            // TRANS: %s is the name of the site.
+            $this->element('h2', null, sprintf(_m('Friends already using %s:'),
                 common_config('site', 'name')));
             $this->elementStart('ul', array('id' => 'facebook-friends'));
 
@@ -140,7 +139,7 @@ class FacebookinviteAction extends FacebookAction
 
     function title()
     {
-        return sprintf(_('Send invitations'));
+        // TRANS: Page title.
+        return sprintf(_m('Send invitations'));
     }
-
 }