Extension talk:HideSidebar

From MediaWiki.org
Jump to: navigation, search

Hi

I think there's an error in your php syntax. As far as I tried it out, there are missing some " ", that's why I got a notice which said that the constants navigation, text, href, id and active are undefined. When I added "" round these words, the notice disappeared.

Here's the corrected code section, I think it should be like this.

                $bar = array(
                        "navigation" => array(
                                array("text"   => 'Login',
                                      "href"   => $url,
                                      "id"     => 'n-login',
                                      "active" => '')
                        )
                );


Thank you and regards,

Sidian

I've added single quotes around the strings. It should work now, although I haven't tested it. Reach Out to the Truth 00:28, 21 September 2010 (UTC)

[edit] Doesn't work for monobook

This doesn't seem to work for monobook, any reason why?

Affirmative. I would be cool to use it with monobook too. Cheers --[[kgh]] 15:33, 7 September 2011 (UTC)
I found another solution to achieve this, though only advisable on closed wikis. Use Extension:UserFunctions and put the parser function into MediaWiki:Sidebar. $wgEnableSidebarCache must be set to false (standard anyway). Cheers --[[kgh]] 19:20, 25 October 2011 (UTC)
Personal tools
Namespaces

Variants
Actions
Navigation
Support
Download
Development
Communication
Print/export
Toolbox