Fixed site notice for monobook, displayed site notice for board vote
authorTim Starling <tstarling@users.mediawiki.org>
Mon, 31 May 2004 08:43:36 +0000 (08:43 +0000)
committerTim Starling <tstarling@users.mediawiki.org>
Mon, 31 May 2004 08:43:36 +0000 (08:43 +0000)
includes/Setup.php
includes/Skin.php
includes/SkinPHPTal.php
stylesheets/cologneblue.css
stylesheets/monobook/main.css
stylesheets/wikistandard.css
templates/xhtml_slim.pt

index 7a66808..5b5ee09 100644 (file)
@@ -193,6 +193,10 @@ if ( !$wgAllowSysopQueries ) {
        SpecialPage::removePage( "Asksql" );
 }
 
+# Placeholders in case of DB error
+$wgTitle = Title::newFromText( wfMsg( "badtitle" ) );
+$wgArticle = new Article($wgTitle);
+
 # Extension setup functions
 # Entries should be added to this variable during the inclusion 
 # of the extension file. This allows the extension to perform 
index a0ce7a8..ddcfdf3 100644 (file)
@@ -292,7 +292,7 @@ class Skin {
                global $wgUser, $wgOut, $wgSiteNotice;
 
                if( $wgSiteNotice ) {
-                       $note = "\n<div id='notice' style='font-weight: bold; color: red; text-align: center'>$wgSiteNotice</div>\n";
+                       $note = "\n<div id='siteNotice'>$wgSiteNotice</div>\n";
                } else {
                        $note = "";
                }
index eab7936..3ce8d22 100644 (file)
@@ -62,7 +62,7 @@
                        global $wgTitle, $wgArticle, $wgUser, $wgLang, $wgOut;
                        global $wgScript, $wgStylePath, $wgLanguageCode, $wgUseNewInterlanguage;
                        global $wgMimeType, $wgOutputEncoding, $wgUseDatabaseMessages, $wgRequest;
-                       global $wgDisableCounters, $wgLogo, $action, $wgFeedClasses;
+                       global $wgDisableCounters, $wgLogo, $action, $wgFeedClasses, $wgSiteNotice;
                        
                        extract( $wgRequest->getValues( 'oldid', 'diff' ) );
 
 
                        $tpl->setRef( "debug", &$out->mDebugtext );
                        $tpl->set( "reporttime", $out->reportTime() );
-
+                       $tpl->set( "sitenotice", $wgSiteNotice );
+                       
                        $tpl->setRef( "bodytext", &$out->mBodytext );
 
                        $language_urls = array();
index 1bcba66..a138309 100644 (file)
@@ -93,3 +93,7 @@ a.stub { color:#772233; text-decoration:none; }
 h2, h3, h4, h5, h6 { margin-bottom: 0; }
 small { font-size: 75%; }
 
+#siteNotice {
+    border: 1px solid red;
+}
+
index 738fd5f..5ba9b95 100644 (file)
@@ -851,6 +851,10 @@ fieldset.operaprefsection { margin-left: 15em }
 /* debugging tool.. */
 /*div{ border:1px solid #000000;}*/
 
+#siteNotice {
+    border: 1px solid red;
+}
+
 
 /* Mac IE 5.0 fix; floated content turns invisible */
 * > html #column-content {
index 2f70ea5..e852f9f 100644 (file)
@@ -50,3 +50,8 @@ p.catlinks { font-size:small; margin-top:0; text-align:right;}
 td { empty-cells:show; }
 td.bottom { border-top: 1px solid gray; }
 td.top { border-bottom: 1px solid gray; }
+
+
+#siteNotice {
+    border: 1px solid red;
+}
index 9929658..224a5b9 100644 (file)
@@ -28,6 +28,7 @@
            <div tal:condition="catlinks" id="catlinks" tal:content="structure catlinks"></div>
            <h3 id="siteSub" i18n:translate="string:fromwikipedia">From Wikipedia, the free encyclopedia.</h3>
            <div id="contentSub" tal:content="structure subtitle"></div>
+           <div id="siteNotice" tal:condition="sitenotice" tal:content="structure sitenotice"></div>
            <!-- <esi:include src="userxy/message"/> cached per user, purged on new message-->
            <div tal:condition="newtalk" class="usermessage" tal:content="structure newtalk"></div>
            <!-- the content area is cached with the remaining inexpensive skeleton, one version for all.