]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - lib/subscribeform.php
Realtime work in progress: switch makeNoticeData to async -- next we'll load fresh...
[quix0rs-gnu-social.git] / lib / subscribeform.php
index 996729a2816c6bb4d1d4d7dd6ee98a7250164e4e..1cc5b4e48eccc18fda8289afadbab92829cac247 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * Laconica, the distributed open-source microblogging tool
+ * StatusNet, the distributed open-source microblogging tool
  *
  * Form for subscribing to a user
  *
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  *
  * @category  Form
- * @package   Laconica
- * @author    Evan Prodromou <evan@controlyourself.ca>
- * @author    Sarven Capadisli <csarven@controlyourself.ca>
- * @copyright 2009 Control Yourself, Inc.
+ * @package   StatusNet
+ * @author    Evan Prodromou <evan@status.net>
+ * @author    Sarven Capadisli <csarven@status.net>
+ * @copyright 2009 StatusNet, Inc.
  * @license   http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
- * @link      http://laconi.ca/
+ * @link      http://status.net/
  */
 
-if (!defined('LACONICA')) {
+if (!defined('STATUSNET') && !defined('LACONICA')) {
     exit(1);
 }
 
@@ -38,11 +38,11 @@ require_once INSTALLDIR.'/lib/form.php';
  * Form for subscribing to a user
  *
  * @category Form
- * @package  Laconica
- * @author   Evan Prodromou <evan@controlyourself.ca>
- * @author   Sarven Capadisli <csarven@controlyourself.ca>
+ * @package  StatusNet
+ * @author   Evan Prodromou <evan@status.net>
+ * @author   Sarven Capadisli <csarven@status.net>
  * @license  http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
- * @link     http://laconi.ca/
+ * @link     http://status.net/
  *
  * @see      UnsubscribeForm
  */
@@ -80,6 +80,19 @@ class SubscribeForm extends Form
         return 'subscribe-' . $this->profile->id;
     }
 
+
+    /**
+     * class of the form
+     *
+     * @return string of the form class
+     */
+
+    function formClass()
+    {
+        return 'form_user_subscribe ajax';
+    }
+
+
     /**
      * Action of the form
      *
@@ -91,6 +104,17 @@ class SubscribeForm extends Form
         return common_local_url('subscribe');
     }
 
+
+    /**
+     * Legend of the Form
+     *
+     * @return void
+     */
+    function formLegend()
+    {
+        $this->out->element('legend', null, _('Subscribe to this user'));
+    }
+
     /**
      * Data elements of the form
      *
@@ -112,6 +136,6 @@ class SubscribeForm extends Form
 
     function formActions()
     {
-        $this->out->submit('submit', _('Subscribe'));
+        $this->out->submit('submit', _('Subscribe'), 'submit', null, _('Subscribe to this user'));
     }
-}
\ No newline at end of file
+}