I like the skin you have created, but I had a couple of questions.
The Pull down menu in GuMaxDD does not appear to be dynamic, or I'm missing something. The pulldown menus are just a replica of the text in MediaWiki:Sidebar and not dynamically generated like before, ie the ToolBox in monobook.
If there is a way to make the pull-downs dynamic it would be nice to know. I have a piece of code I wrote for monobook that lists your Watchlist as a Favorites link and it would be cool to be able to do the same with the drop-down menus.
An example of a favorites box and the code used can be seen at http://www.losbyers.com/mediawiki/index.php/Wiki_notes. Although, unless you login and add some links to your Watchlist the Favorite box will be empty. It has been very handy to be able to add and remove pages from the favorites as needed, ie you are working on a document it's "bookmarked", but when you are done you can remove it.
Thanks
TMM
Editing MediaWiki:Sidebar
- TheMilkman
- Rank 0
- Posts: 3
- Joined: July 28th, 2009, 3:49 pm
Re: Editing MediaWiki:Sidebar
I'm not sure what your "dynamic" means, I'm pretty sure you miss something or misunderstand something. My suggestion is to read the skin page and sample carefully at http://paulgu.com/wiki/Drop_Down_Menu_Series.
- TheMilkman
- Rank 0
- Posts: 3
- Joined: July 28th, 2009, 3:49 pm
Re: Editing MediaWiki:Sidebar
From the page you link it looks like to build the pull-down menus you have to have static links in the MediaWiki:Sidebar page. The admin places the links there and they are the same for every user.
If I wanted the users to be able to have their own "Favorites" pull-down menu the data for the menu would need to be different for each user, thus it would need to be dynamically built, not static.
Sort of like the function you have "function wikiSpecialToolBox()" which dynamically builds the toolbox items in the page footer. I would want a function that builds a pull-down menu.
If I wanted the users to be able to have their own "Favorites" pull-down menu the data for the menu would need to be different for each user, thus it would need to be dynamically built, not static.
Sort of like the function you have "function wikiSpecialToolBox()" which dynamically builds the toolbox items in the page footer. I would want a function that builds a pull-down menu.
- TheMilkman
- Rank 0
- Posts: 3
- Joined: July 28th, 2009, 3:49 pm
Re: Editing MediaWiki:Sidebar
Well I got it figured out.
If you want dynamic pull-down menus that are generated from PHP code and not statically set from the MediaWiki:Sidebar then you need to add your own menu items to the gumaxdd.php script. The pull-downs will be after anything listed in the MediaWiki:Sidebar.
Example:
Right after the code in the mainNavigationBox() function.
FIND
ADD after
I was able to build a pull-down with a Title of "Favorites" and the items listed were those on each persons Watch List
If you want dynamic pull-down menus that are generated from PHP code and not statically set from the MediaWiki:Sidebar then you need to add your own menu items to the gumaxdd.php script. The pull-downs will be after anything listed in the MediaWiki:Sidebar.
Example:
Right after the code in the mainNavigationBox() function.
FIND
Code: Select all
} else {
# allow raw HTML block to be defined by extensions
//print $cont;
}
?>
</li>
<?php } ?>
Code: Select all
<li> <a href="<?php $this->text('scriptpath') ?>/index.php?title=Favorites">Favorites </a>
<ul>
<?php
** The PHP code to build a list of <li> stuff </li> **
?>
</ul>
</li>
Re: Editing MediaWiki:Sidebar
This is great, however it's not part of skin... more like enhancement or customization... The skin has to be general.