]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - plugins/Awesomeness/AwesomenessPlugin.php
Merge branch 'nightly' of git.gnu.io:gnu/gnu-social into mmn_fixes
[quix0rs-gnu-social.git] / plugins / Awesomeness / AwesomenessPlugin.php
index 31f8ea35f4f66bc07c2d8d01d05a594dd332346c..ca3b281df681c80ebb288f01d070c39bbb674607 100644 (file)
@@ -42,9 +42,9 @@ if (!defined('STATUSNET')) {
 
 class AwesomenessPlugin extends Plugin
 {
-       const VERSION = '0.0.42';
+    const VERSION = '0.0.42';
 
-    public function onPluginVersion(&$versions)
+    public function onPluginVersion(array &$versions)
     {
         $versions[] = array(
             'name' => 'Awesomeness',
@@ -52,8 +52,7 @@ class AwesomenessPlugin extends Plugin
             'author' => 'Jeroen De Dauw',
             'homepage' => 'http://status.net/wiki/Plugin:Awesomeness',
             // TRANS: Plugin description for a sample plugin.
-            'rawdescription' => _m(
-                'The Awesomeness plugin adds additional awesomeness ' .
+            'rawdescription' => _m('The Awesomeness plugin adds additional awesomeness ' .
                 'to a StatusNet installation.'
             )
         );
@@ -72,22 +71,22 @@ class AwesomenessPlugin extends Plugin
         $action->elementStart('div', array('id' => 'cornify_section',
                                          'class' => 'section'));
 
-       $action->raw(
-       <<<EOT
-               <a href="http://www.cornify.com" onclick="cornify_add();return false;">
-               <img src="http://www.cornify.com/assets/cornify.gif" width="61" height="16" border="0" alt="Cornify" />
-               </a>
-       <script type="text/javascript">(function() {
-       var js = document.createElement('script');
-       js.type = 'text/javascript';
-       js.async = true;
-       js.src = 'http://www.cornify.com/js/cornify.js';
-       (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(js);
+        $action->raw(
+        <<<EOT
+                <a href="http://www.cornify.com" onclick="cornify_add();return false;">
+                <img src="http://www.cornify.com/assets/cornify.gif" width="61" height="16" border="0" alt="Cornify" />
+                </a>
+        <script type="text/javascript">(function() {
+        var js = document.createElement('script');
+        js.type = 'text/javascript';
+        js.async = true;
+        js.src = 'http://www.cornify.com/js/cornify.js';
+        (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(js);
 })();</script>
 EOT
-       );
+        );
 
-       $action->elementEnd('div');
+        $action->elementEnd('div');
     }
 
     /**
@@ -102,7 +101,7 @@ EOT
      */
     function onStartSaveNewNoticeWeb($action, $user, &$content, &$options)
     {
-       $content = htmlspecialchars($content);
-       $options['rendered'] = preg_replace("/(^|\s|-)((?:awesome|awesomeness)[\?!\.\,]?)(\s|$)/i", " <b>$2</b> ", $content);
+        $content = htmlspecialchars($content);
+        $options['rendered'] = preg_replace("/(^|\s|-)((?:awesome|awesomeness)[\?!\.\,]?)(\s|$)/i", " <b>$2</b> ", $content);
     }
 }