]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - plugins/GNUsocialTemplatePlugin.php
RepeatAction extends FormAction (and ManagedAction)
[quix0rs-gnu-social.git] / plugins / GNUsocialTemplatePlugin.php
old mode 100755 (executable)
new mode 100644 (file)
index 6d5c606..7db2f73
@@ -1,8 +1,8 @@
 <?php
 /**
- * Plugin to render old skool templates
+ * Plugin to render GNU social
  *
- * Captures rendered parts from the output buffer, passes them through a template file: tpl/index.html
+ * Captures rendered parts from the output buffer, passes them through a template file: tpl/social.php
  * Adds an API method at index.php/template/update which lets you overwrite the template file
  * Requires username/password and a single POST parameter called "template"
  * The method is disabled unless the user is #1, the first user of the system
@@ -10,7 +10,9 @@
  * @category  Plugin
  * @package   StatusNet
  * @author    Brian Hendrickson <brian@megapump.com>
+ * @author    Matt Lee <mattl@cnuk.org>
  * @copyright 2009 Megapump, Inc.
+ * @copyright 2010 Free Software Foundation, Inc.
  * @license   http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
  * @link      http://megapump.com/
  */
@@ -44,7 +46,7 @@ class TemplatePlugin extends Plugin {
   // <%feeds%>
   // <%description%>
   // <%head%>
-  function onStartShowHead( &$act ) {
+  function onStartShowHead( $act ) {
     $this->clear_xmlWriter($act);
     $act->extraHead();
     $this->blocks['head'] = $act->xw->flush();
@@ -62,29 +64,29 @@ class TemplatePlugin extends Plugin {
   }
 
   // <%bodytext%>
-  function onStartShowContentBlock( &$act ) {
+  function onStartShowContentBlock( $act ) {
     $this->clear_xmlWriter($act);
     return true;
   }
-  function onEndShowContentBlock( &$act ) {
+  function onEndShowContentBlock( $act ) {
     $this->blocks['bodytext'] = $act->xw->flush();
   }
 
   // <%localnav%>
-  function onStartShowLocalNavBlock( &$act ) {
+  function onStartShowLocalNavBlock( $act ) {
     $this->clear_xmlWriter($act);
     return true;
   }
-  function onEndShowLocalNavBlock( &$act ) {
+  function onEndShowLocalNavBlock( $act ) {
     $this->blocks['localnav'] = $act->xw->flush();
   }
 
   // <%export%>
-  function onStartShowExportData( &$act ) {
+  function onStartShowExportData( $act ) {
     $this->clear_xmlWriter($act);
     return true;
   }
-  function onEndShowExportData( &$act ) {
+  function onEndShowExportData( $act ) {
     $this->blocks['export'] = $act->xw->flush();
   }
 
@@ -100,7 +102,7 @@ class TemplatePlugin extends Plugin {
   // <%groupsbyposts%>
   // <%featuredusers%>
   // <%groupsbymembers%>
-  function onStartShowSections( &$act ) {
+  function onStartShowSections( $act ) {
     global $action;
     $this->clear_xmlWriter($act);
     switch ($action) {
@@ -153,7 +155,7 @@ class TemplatePlugin extends Plugin {
   // <%nav%>
   // <%notice%>
   // <%noticeform%>
-  function onStartShowHeader( &$act ) {
+  function onStartShowHeader( $act ) {
     $this->clear_xmlWriter($act);
     $act->showLogo();
     $this->blocks['logo'] = $act->xw->flush();
@@ -172,7 +174,7 @@ class TemplatePlugin extends Plugin {
 
   // <%secondarynav%>
   // <%licenses%>
-  function onStartShowFooter( &$act ) {
+  function onStartShowFooter( $act ) {
     $this->clear_xmlWriter($act);
     $act->showSecondaryNav();
     $this->blocks['secondarynav'] = $act->xw->flush();
@@ -240,13 +242,13 @@ class TemplatePlugin extends Plugin {
   }
 
   // catching the StartShowHTML event to halt the rendering
-  function onStartShowHTML( &$act ) {
+  function onStartShowHTML( $act ) {
     $this->clear_xmlWriter($act);
     return true;
   }
 
   // clear the xmlWriter
-  function clear_xmlWriter( &$act ) {
+  function clear_xmlWriter( $act ) {
     $act->xw->openMemory();
     $act->xw->setIndent(true);
   }