]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/publictagcloud.php
Merge branch '0.8.x' of git@gitorious.org:laconica/dev into 0.8.x
[quix0rs-gnu-social.git] / actions / publictagcloud.php
index 5322372b2a12baa7fb65b98973f2452d3643f566..e9f33d58b6d95df7925a07355e20ec31217f1c38 100644 (file)
@@ -47,7 +47,7 @@ define('TAGS_PER_PAGE', 100);
 
 class PublictagcloudAction extends Action
 {
-    function isReadOnly()
+    function isReadOnly($args)
     {
         return true;
     }
@@ -62,13 +62,11 @@ class PublictagcloudAction extends Action
         $this->element('p', 'instructions',
                        sprintf(_('These are most popular recent tags on %s '),
                                common_config('site', 'name')));
+    }
 
-        $tags = new Notice_tag();
-        if ($tags->count()) {
-            return;
-        }
-
-        $message = _('Noone has posted a notice with a [hashtag](%%doc.tags%%) yet.') . ' ';
+    function showEmptyList()
+    {
+        $message = _('No one has posted a notice with a [hashtag](%%doc.tags%%) yet.') . ' ';
 
         if (common_logged_in()) {
             $message .= _('Be the first to post one!');
@@ -77,7 +75,7 @@ class PublictagcloudAction extends Action
             $message .= _('Why not [register an account](%%action.register%%) and be the first to post one!');
         }
 
-        $this->elementStart('div', 'blankfiller');
+        $this->elementStart('div', 'guide');
         $this->raw(common_markup_to_html($message));
         $this->elementEnd('div');
     }
@@ -144,6 +142,8 @@ class PublictagcloudAction extends Action
             $this->elementEnd('dd');
             $this->elementEnd('dl');
             $this->elementEnd('div');
+        } else {
+            $this->showEmptyList();
         }
     }