Extension talk:SpecialPagesOrganizer
$egOrderRP - small fix
editIf you can't sort restricted pages, it's because the global $egOrderRP is not declared in hook function. Change line
global $wgOut, $wgUser, $egDisplayNCSP;
with:
global $wgOut, $wgUser, $egDisplayNCSP, $egOrderRP;
and btw, very nice extension, thanks :) --Ader 07:23, 2 June 2008 (UTC)
Suggestion
editHi! After testing this extension I found out that it was very hard to see if all specialpages was included in the arrays. It would be nice if this extension had the ability to add all non-categorized Specialpages to another section at the bottom of the page.
- I like this suggestion. I will implement it this weekend maybe. Currently I am swamped with midterms. --DFRussia 01:15, 24 October 2007 (UTC)
Error
edithi, i get always this error Warning: call_user_func(efReoderSpecial) [function.call-user-func]: First argument is expected to be a valid callback in ...\includes\Setup.php on line 219 Any idea?
- How are you including the function, and what are you including?
- I'm getting a similar error in MW 1.11:
- Warning: call_user_func(efReoderSpecial) function.call-user-func: First argument is expected to be a valid callback in includes/Setup.php on line 287
284 foreach ( $wgExtensionFunctions as $func ) { 285 $profName = $fname.'-extensions-'.strval( $func ); 286 wfProfileIn( $profName ); 287 call_user_func( $func ); 288 wfProfileOut( $profName );
- -Marc 09/27/07 7:59pm EST
- I will look into the error you are getting when I find sometime. I am not sure what is causing it but I will try to simulate it on my system. Thank you for your feedback --DFRussia 14:17, 2 October 2007 (UTC)
- This is because there's a typo in the extension - note how it says "efReoderSpecial" instead of "efReorderSpecial". However, fixing that yields more errors which I haven't been able to figure out yet. -- Schneelocke 18:56, 10 October 2007 (UTC)
- The other errors are due to the fact that
$wgExtensionFunctions
is being used the wrong way; it's apparently supposed to contain initialisation functions for extensions, and efReorderSpecial isn't one. Removing the line entirely gets rid of the above warning, but the fatal error below still says. I'll look into that. -- Schneelocke 19:55, 10 October 2007 (UTC)
- I will look into the error you are getting when I find sometime. I am not sure what is causing it but I will try to simulate it on my system. Thank you for your feedback --DFRussia 14:17, 2 October 2007 (UTC)
- -Marc 09/27/07 7:59pm EST
I got the same Error an additionaly this:
Fatal error: Call to a member function isListed() on a non-object in C:\xampp\htdocs\wiki\extensions\organizer\SpecialPagesOrganizer.php on line 55
I'm working in the German Wiki on my own Mediawiki and i includet this array's:
$egOrderArray["<Wiki Spezialseiten>"] = array('Alle Seiten', 'Alle Seiten(mit Präfix)', 'Anmelden', 'Begriffsklärungsseiten', 'Beliebte Seiten', 'Benutzerbeiträge', 'Benutzerverzeichnis', 'Benutzte, aber nicht angelegte Kategorien', 'Beobachtungsliste', 'Dateiliste', 'Doppelte Weiterleitungen', 'Einstellungen', 'Geschützte Seiten', 'Gewünschte Seiten', 'Hauptautoren', 'Hochladen', 'Häufig verlinkte Seiten', 'ISBN-Suche', 'Kaputte Weiterleitungen', 'Kategorien', 'Kurze Seiten', 'Lange Seiten', 'Letzte Änderungen', 'Liste gesperrter Benutzer/IP-Adressen', 'Logbücher', 'MediaWiki-Systemtexte', 'Meistbenutzte Dateien', 'Meistbenutzte Kategorien', 'Meistkategorisierte Seiten', 'Neue Dateien', 'Neue Seiten', 'Neueste Seiten', 'Nicht benutzte Vorlagen', 'Nicht kategorisierte Dateien', 'Nicht kategorisierte Kategorien', 'Nicht kategorisierte Seiten', 'Sackgassenseiten', 'Seit längerem unbearbeitete Artikel', 'Seiten exportieren', 'Seiten mit den meisten Versionen', 'Seiten mit den wenigsten Versionen', 'Seiten ohne Links zu anderen Sprachen', 'Statistik', 'Suche', 'Suche nach MIME-Typ', 'Version', 'Verwaiste Dateien', 'Verwaiste Kategorien', 'Verwaiste Seiten', 'Weiterleitungsliste', 'Zufällige Seite', 'Zufällige Weiterleitung'); $egOrderArray["<Administrative Spezialseiten>"] = array( 'Benutzerrechteverwaltung', 'Datenbank freigeben', 'Datenbank sperren', 'Gelöschte Seite wiederherstellen', 'IP-Adresse/Benutzer sperren', 'Nicht beobachtete Seiten', 'Seiten importieren', 'UserScore'); require_once( "$IP/extensions/organizer/SpecialPagesOrganizer.php");
The Path is correct and i copied the conetend on this Article. Someone can help me please?
- You have to use the names that the pages register themselves with... the names in the code, which are all in English, as far as I know. --DFRussia 04:43, 2 October 2007 (UTC)
Error with Semantic form
editHi Artem Kaznatcheev. Would you like to give a hand that if I'v installed the Semantic Forms, this extension will not show the special-page-items of Semantic MediaWiki (SW) and Semantic Forms (SWF) in the Special:Specialpages but It's really need to use this extension when I'v installed SW and SWF, because their spacial page are too much to let users to see them clearly. Thank you.
- ps. I'v add the code in the localsetting.php
$egOrderArray['semantic_wiki'] = array(
'Add data',
'Add page',
'Attributes',
'Browse wiki',
'Call',
'Create a form',
'Create a semantic property',
'Create a template',
'Edit data',
'Export pages to RDF',
'Extended Statistics',
'Forms',
'Relations',
'Search by attribute',
'Search by relation',
'Semantic search',
'Templates',
'Types',
'Unused attributes',
'Unused relations',
'View and manipulate interwiki data',
'Wanted relations',
);
--Roc michael 10:53, 23 September 2007 (UTC)
- You got to make sure to use the proper internal extension name. Not the name of the actual page. The one the Special Page registers itself with. When I have time I can look at those things I will find out their real names --DFRussia 04:41, 2 October 2007 (UTC)
efReorderSpecial failed to return a value
editI'm getting this error:
Detected bug in an extension! Hook efReorderSpecial failed to return a value; should return true to continue hook processing or false to abort. Backtrace: #0 F:\wiki\includes\SpecialPage.php(651): wfRunHooks('SpecialPageExec...', Array) #1 F:\wiki\includes\SpecialPage.php(459): SpecialPage->execute(NULL) #2 F:\wiki\includes\Wiki.php(201): SpecialPage::executePath(Object(Title)) #3 F:\wiki\includes\Wiki.php(45): MediaWiki->initializeSpecialCases(Object(Title), Object(OutputPage), Object(WebRequest)) #4 F:\wiki\index.php(88): MediaWiki->initialize(Object(Title), Object(OutputPage), Object(User), Object(WebRequest)) #5 {main}
Any idea how to fix this? It happens even if I have only one special page named in my $egOrderArray. MediaWiki 1.11.0. --Jonathan Kovaciny 18:34, 2 October 2007 (UTC)
- Hmmm, weird. That is a very descriptive error. My schedule is very busy until this weekend, but I will look into it this weekend and get back to you with what might be causing the error. I never really did good error checking on this extension (since I used it for one little thing and I did not think other people would want it). I will look into fixing the numerous errors reported, improving documentation and releasing it all as one new, awesome update. If I don't start putting some sort of stuff up this weekend, feel free to remind me. Thanks for the feedback --DFRussia 08:22, 4 October 2007 (UTC)
- I had
$wgShowExceptionDetails = true;
in my LocalSettings.php, which is why it spit out so much info. It seems like a great extension to me; the Special Pages page is so unorganized to me. Alphabetical only works when things all have the same purpose or function, and have only one reasonable name. Thanks for your work! --Jonathan Kovaciny 19:29, 4 October 2007 (UTC)
- I had
Errors resolved
editHi, I also got the "Fatal error: Call to a member function isListed() on a non-object" error mentioned above, so I tinkered around for a bit more. The problem is Special:Random - you'd be tempted to include "Random" in the $egOrderArray
s, but the correct name is actually "Randompage".
The other half of the problem is that this extension simply chokes on invalid pages. This is easily fixed, though: in efReorderSpecialpages_gen
, replace the line that says
if ( $page->isListed() ) {
with
if ( $page && $page->isListed() ) {
and everything should be fine. There's another unrelated bug left: the extension function needs to return true or false. Given that we don't want the "regular" lists of special pages to show up anymore, we should return false. I'll update the code on the content page with these fixes and the fix for the warning I mentioned above if you don't mind. -- Schneelocke 20:13, 10 October 2007 (UTC)
Rename special pages
editIs there a way to rename the links to the Special Pages? I don't necessarily want to rename the SP themselves, just to rename the links. For example, instead of "User list" linking to Special:Listusers, I want it to be labeled "All users". –Jonathan Kovaciny 16:41, 5 March 2008 (UTC)
- I can work on that for next release. However, I am very busy now a days, so that release might take a little while. How urgently do you need it? --DFRussia 05:40, 6 March 2008 (UTC)
- Okay, felt like doing a little coding before sleep, so I implemented it. Hopefully this is what you where looking for. --DFRussia 08:01, 8 March 2008 (UTC)
- Perfect, thanks! –Jonathan Kovaciny 15:51, 10 March 2008 (UTC)
- Okay, felt like doing a little coding before sleep, so I implemented it. Hopefully this is what you where looking for. --DFRussia 08:01, 8 March 2008 (UTC)
Ideas
editI am thinking of the next feature to add is some JavaScript functionality. Most notably, the ability to collapse and uncollapse "sections". What does everyone think? Another, more fancy, feature I was thinking about was allowing to load the special pages right on this page, so the user can go through several pages quickly, without having to navigate away... this is not a priority, but I thought it would be fun. Does anyone have any ideas for dynamic functionality they would like to see in the SpecialPagesOrganizer? Give me some feedback, and I will try to implement it --DFRussia 06:24, 25 March 2008 (UTC)
Very nice
editI like it, thanks.
I'd like to see the sections multi-columned and unsorted (ie, the order is given by the order in LocalSettings -- if possible). --Otheus 17:29, 9 July 2008 (UTC)
I support the multi-column suggestion. It makes things more compact and really nice. http://zeldawiki.org/Special:SpecialPages has extended theirs to do this and it looks great. official support with toggles usable in LocalSettings.php would be the best option to toggle this. --Tekmosis 18:58, 2 September 2008 (UTC)
- Thanks for the feedback! I will incorporate these ideas into the next release, they shouldn't be too hard to do. I will code it once school settles down a bit. Cheers --DFRussia 05:19, 3 September 2008 (UTC)