]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Show NoticeForm only if logged in
authorEvan Prodromou <evan@controlyourself.ca>
Thu, 15 Jan 2009 22:25:26 +0000 (22:25 +0000)
committerEvan Prodromou <evan@controlyourself.ca>
Thu, 15 Jan 2009 22:25:26 +0000 (22:25 +0000)
lib/action.php

index d106ba36667f4f05da25a83944c11f384ab4ab82..9df39e9a820ed5d2e938ff4e55722816add5e635 100644 (file)
@@ -208,7 +208,11 @@ class Action extends HTMLOutputter // lawsuit
         $this->showLogo();
         $this->showPrimaryNav();
         $this->showSiteNotice();
-        $this->showNoticeForm();
+       if (common_logged_in()) {
+           $this->showNoticeForm();
+       } else {
+           $this->showAnonymousMessage();
+       }
         $this->elementEnd('div');
     }
 
@@ -285,6 +289,11 @@ class Action extends HTMLOutputter // lawsuit
         $notice_form->show();
     }
 
+    function showAnonymousMessage()
+    {
+       // needs to be defined by the class
+    }
+    
     function showCore()
     {
         $this->elementStart('div', array('id' => 'core'));