Book Image

MediaWiki Skins Design

Book Image

MediaWiki Skins Design

Overview of this book

Table of Contents (16 chapters)
MediaWiki Skins Design
Credits
About the Author
About the Reviewer
Preface

Changing the Content Area: #bodyContent


If you study the XHTML output from the MonoBook theme, you will notice that the page's primary content is positioned above the "interface" elements such as the userbar, page navigation, and the logo. This helps to improve the meaning of the page's content.

Page Anchors

Towards the top of the document, you will see <a name="top" id="top"></a> as an anchor, identified by #top. This allows you to include a "back to the top of this page" link within your wiki's design. This is unused in MediaWiki's MonoBook skin, but we can use it for the JazzMeet skin by inserting a link in our template just above the</div> of #bodyContent (the added code is highlighted):

<!-- start content -->
<?php $this->html('bodytext') ?>
<?php if($this->data['catlinks']) { ?><div id="catlinks"><?php $this->html('catlinks') ?></div><?php } ?>
<p id="f-top">
<a href="#top" title="Return to the top of this...