Last modified: 2014-07-11 21:04:34 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 T69702, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 67702 - If a filename begins with a capital letter, filelist search fails
If a filename begins with a capital letter, filelist search fails
Status: NEW
Product: MediaWiki
Classification: Unclassified
Search (Other open bugs)
1.22.0
All Linux
: Low normal (vote)
: ---
Assigned To: Nobody - You can work on this!
http://www.mediawiki.org/wiki/Thread:...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-07-08 23:38 UTC by atlantonius
Modified: 2014-07-11 21:04 UTC (History)
2 users (show)

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


Attachments

Description atlantonius 2014-07-08 23:38:23 UTC
in 1.22, if a filename begins with a capital letter, searching fails if your search criteria includes the capital letter.  If you omit the first character, it works fine.

I found this to be because of the following line in /includes/special/SpecialListfiles.php, Line 138:
 $conds[] = 'LOWER(' . $prefix . '_name)' .

If this is changed to the following, you can now search using a capital letter:
 $conds[] = 'CONVERT(' . $prefix . '_name USING latin1)' .


Originally found by Fereal in a previous version, I simply adopted their solution for the new function in 1.22.  Link to that discussion below:
http://www.mediawiki.org/wiki/Thread:Project:Support_desk/Search_function_in_File_list_doesn't_work_properly
Comment 1 Chad H. 2014-07-11 21:04:34 UTC
CONVERT(' . $prefix . '_name USING latin1) will break for pretty much everyone other than MySQL.

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


Navigation
Links