Hi, Is there a way to include the Mediawiki:Sidebar items in the menu ?
Topic on Extension talk:MobileFrontend
I found a trashy hack
/**
* Render side menu as lists
* @param array $data Data used to build the page
*/
protected function renderMainMenu( $data ) {
?>
<ul>
<?php
foreach( $this->getDiscoveryTools() as $key => $val ):
echo $this->makeListItem( $key, $val );
endforeach;
?>
</ul>
<?php // PATCH FSN : Ajout des la sidebar
echo "<ul style="border-bottom: 12px solid #252525;">";
foreach ($this->data['sidebar'] as $bar => $cont) {
foreach($cont as $key => $val) {
echo $this->makeListItem( $key, $val, array ('link-class' => 'icon icon-nearby icon-text') );
}
}
echo " </ul>";
// FIN PATCH FSN
?>
<ul>
<?php
foreach( $this->getPersonalTools() as $key => $val ):
For what this is worth, the English wikisource has a javascript+CSS gadget for this as well: MediaWiki:Gadget-FlatSidebar.js & MediaWiki:Gadget-FlatSidebar.css. (A warning, though, this code is probably very specific to the Vector skin in that environment.)
where does this code go ? could you attribute the code, have a link to the original ? thank you!
this function is in includes/skins/MinervaTemplate.php:
see the above subject: MODIFY THE MAIN MENU
is easy to add items ^_^