Last modified: 2011-06-16 22:54:05 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T31441, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 29441 - Expose CapitalLinks config in JS to allow modules to properly handle titles on case-sensitive wikis
Expose CapitalLinks config in JS to allow modules to properly handle titles o...
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
JavaScript (Other open bugs)
1.20.x
All All
: Unprioritized normal (vote)
: ---
Assigned To: Krinkle
:
Depends on:
Blocks: 29397
  Show dependency treegraph
 
Reported: 2011-06-16 20:55 UTC by Krinkle
Modified: 2011-06-16 22:54 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Krinkle 2011-06-16 20:55:29 UTC
Several scripts have been braking on wiktionary-like wikis since forever, resulting in per-wiki hardcoded hacks.

Although exposing $wgCapitalLinkOverrides and/or $wgCapitalLinks directly is no good, a simple array that matches MWNamespace::isCapital would be nice.

The reason those config variables aren't useful rightaway is due to the logic behind MWNamespace::isCapital (ie. Media->File, $alwaysCapitalizedNamespaces, getSubject(), etc.)

Since this would probably end up in a loop, we can re-use the loop introduced in r90096 for wgNamespaceIds.

This bug is blocking proper integration of the mw.Title constructor, which currently (in UploadWizard) harccodes ucFirst() – not a big deal since it's targetting Wikimedia Commons, but for core it needs to be fixed.

ie. on a wiki with a case-sensitive main-namespace the following is happening that could be breaking many things:
> var title = new mw.Title( 'apple' );
> title.toString()
"Apple"
Comment 1 Krinkle 2011-06-16 21:22:17 UTC
Fixed in r90234.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links