Last modified: 2007-12-31 22:42:57 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 12451 - Title canonicalisation in AjaxFunctions.php
Title canonicalisation in AjaxFunctions.php
Product: MediaWiki
Classification: Unclassified
Interface (Other open bugs)
All All
: Normal trivial (vote)
: ---
Assigned To: Nobody - You can work on this!
Depends on:
  Show dependency treegraph
Reported: 2007-12-30 03:18 UTC by Nathanael
Modified: 2007-12-31 22:42 UTC (History)
0 users

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

AjaxFunctions.php diff (2.21 KB, patch)
2007-12-30 03:18 UTC, Nathanael

Description Nathanael 2007-12-30 03:18:07 UTC
Created attachment 4484 [details]
AjaxFunctions.php diff

The attached diff makes AjaxFunctions.php (revision 28538) more respectful of case and underscores in titles.

Motivation: I use a slightly modified mediawiki for a technical wiki where case and underscores are significant in page titles. This relies on titles being treated correctly. In particular, newFromText should not be used where the title has already been canonicalised into DB key form.

Changes include:
* wfSajaxSearch:
 - Do not add underscores (Title::newFromText will do that).
 - Do not apply ucfirst to the search term unless wgCapitalLinks is true.
 - Use Title::makeTitle directly instead of Title::newFromText when using fields directly from the database (or the Special Pages lists).

* wfAjaxWatch
 - Use Title::newFromDBkey instead of Title::newFromText in the wfAjaxWatch, where $pagename is already a DB key.
Comment 1 Brion Vibber 2007-12-31 22:42:57 UTC
Applied in r29132

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