]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/invite.php
Merge remote-tracking branch 'mainline/1.0.x' into people_tags_rebase
[quix0rs-gnu-social.git] / actions / invite.php
index 2779437e0c3ccc1fb94f6eff8cc3efc4425d5e5c..7a1f8b3f5b16d4f9aac0ac8df6d9dc9a64d34bd9 100644 (file)
@@ -19,6 +19,7 @@
 
 if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); }
 
+// @todo XXX: Add documentation.
 class InviteAction extends CurrentUserDesignAction
 {
     var $mode = null;
@@ -53,9 +54,10 @@ class InviteAction extends CurrentUserDesignAction
 
     function sendInvitations()
     {
-        # CSRF protection
+        // CSRF protection
         $token = $this->trimmed('token');
         if (!$token || $token != common_session_token()) {
+            // TRANS: Client error displayed when the session token does not match or is not given.
             $this->showForm(_('There was a problem with your session token. Try again, please.'));
             return;
         }
@@ -142,7 +144,7 @@ class InviteAction extends CurrentUserDesignAction
             $this->elementStart('ul');
             foreach ($this->already as $other) {
                 // TRANS: Used as list item for already subscribed users (%1$s is nickname, %2$s is e-mail address).
-                $this->element('li', null, sprintf(_('%1$s (%2$s)'), $other->nickname, $other->email));
+                $this->element('li', null, sprintf(_m('INVITE','%1$s (%2$s)'), $other->nickname, $other->email));
             }
             $this->elementEnd('ul');
         }
@@ -156,7 +158,7 @@ class InviteAction extends CurrentUserDesignAction
             $this->elementStart('ul');
             foreach ($this->subbed as $other) {
                 // TRANS: Used as list item for already registered people (%1$s is nickname, %2$s is e-mail address).
-                $this->element('li', null, sprintf(_('%1$s (%2$s)'), $other->nickname, $other->email));
+                $this->element('li', null, sprintf(_m('INVITE','%1$s (%2$s)'), $other->nickname, $other->email));
             }
             $this->elementEnd('ul');
         }
@@ -217,7 +219,7 @@ class InviteAction extends CurrentUserDesignAction
         $this->textarea('addresses', _('Email addresses'),
                         $this->trimmed('addresses'),
                         // TRANS: Tooltip for field label for a list of e-mail addresses.
-                        _('Addresses of friends to invite (one per line)'));
+                        _('Addresses of friends to invite (one per line).'));
         $this->elementEnd('li');
         $this->elementStart('li');
         // TRANS: Field label for a personal message to send to invitees.
@@ -288,7 +290,7 @@ class InviteAction extends CurrentUserDesignAction
         mail_send($recipients, $headers, $body);
     }
 
-    function showLocalNav()
+    function showObjectNav()
     {
         $nav = new SubGroupNav($this, common_current_user());
         $nav->show();