Fix http://bugzilla.wikipedia.org/show_bug.cgi?id=538
[lhc/web/wiklou.git] / skins / Nostalgia.php
1 <?php
2 /**
3 * See skin.doc
4 *
5 * @todo document
6 * @package MediaWiki
7 * @subpackage Skins
8 */
9
10 /**
11 * @todo document
12 * @package MediaWiki
13 * @subpackage Skins
14 */
15 class SkinNostalgia extends Skin {
16
17 function initPage() {
18 # ...
19 }
20
21 function getStylesheet() {
22 return 'common/nostalgia.css';
23 }
24 function getSkinName() {
25 return "nostalgia";
26 }
27
28 function doBeforeContent() {
29 global $wgUser, $wgOut, $wgTitle, $wgSiteNotice;
30
31 $s = "\n<div id='content'>\n<div id='topbar'>";
32 $s .= $this->logoText( "right" );
33
34 $s .= $this->pageTitle();
35 $s .= $this->pageSubtitle() . "\n";
36
37 $s .= $this->topLinks() . "\n<br />";
38 if( $wgSiteNotice ) {
39 $s .= "\n<div id='siteNotice'>$wgSiteNotice</div>\n";
40 }
41 $s .= $this->pageTitleLinks();
42
43 $ol = $this->otherLanguages();
44 if($ol) $s .= "<br />" . $ol;
45
46 $cat = $this->getCategoryLinks();
47 if($cat) $s .= "<br />" . $cat;
48
49 $s .= "<br clear='all' /><hr />\n</div>\n";
50 $s .= "\n<div id='article'>";
51
52 return $s;
53 }
54
55 function topLinks() {
56 global $wgOut, $wgUser;
57 $sep = " |\n";
58
59 $s = $this->mainPageLink() . $sep
60 . $this->specialLink( "recentchanges" );
61
62 if ( $wgOut->isArticle() ) {
63 $s .= $sep . $this->editThisPage()
64 . $sep . $this->historyLink();
65 }
66 if ( 0 == $wgUser->getID() ) {
67 $s .= $sep . $this->specialLink( "userlogin" );
68 } else {
69 $s .= $sep . $this->specialLink( "userlogout" );
70 }
71 $s .= $sep . $this->specialPagesList();
72
73 return $s;
74 }
75
76 function doAfterContent() {
77 global $wgUser, $wgOut;
78
79 $s = "\n</div><br clear='all' />\n";
80
81 $s .= "\n<div id='footer'><hr />";
82
83 $s .= $this->bottomLinks();
84 $s .= "\n<br />" . $this->pageStats();
85 $s .= "\n<br />" . $this->mainPageLink()
86 . " | " . $this->aboutLink()
87 . " | " . $this->searchForm();
88
89 $s .= "\n</div>\n</div>\n";
90
91 return $s;
92 }
93 }
94
95 ?>