Page MenuHomePhabricator

Allow to add categories from a dropdown in Special:Upload
Open, LowPublicFeature

Description

Author: webmaster

Description:
Wikipedia's upload page seems to have a SpecialUpload.php hack
(http://en.wikipedia.org/wiki/Special:Upload) which contains a dropdown for
licensing information.

It would be extremely helpful to bring that functionality to the core for all
other MediaWiki users as well.

What I propose is two drop downs, enabled/disabled in localSettings.php, for
categorization and licensing tags. The localSettings.php entries would have an
array() which would contain the data for each of the customizable dropdowns.

eg. $wgLicenseArray('Fair Use', '{{fairuse}}');
eg. $wgCategoryArray('Images of People', '{{peopleimages}}');

I believe even Wikipedia could benefit by soft-coding the customizable
dropdowns, instead of using a hard-coded SpecialUpload.php hack.


Version: unspecified
Severity: enhancement
URL: http://en.wikipedia.org/wiki/Special:Upload

Details

Reference
bz5234

Event Timeline

bzimport raised the priority of this task from to Low.Nov 21 2014, 9:07 PM
bzimport set Reference to bz5234.
bzimport added a subscriber: Unknown Object (MLST).

robchur wrote:

Well this bug report is nice and quick to resolve. The functionality described
does indeed exist in MediaWiki; version 1.6. See, for instance,
http://en.wikipedia.org/wiki/MediaWiki:Licenses to see how it's set up using
templates and licence descriptors.

webmaster wrote:

Hey Rob!

Thanks for the info, I didn't know about that.

I have a quick question for you...
Does it also allow for a second/third/etc dropdown?

As I mentioned, I was hoping for not only a license dropdown, but one for image
categorization, too...

webmaster wrote:

I have re-opened the enhancement request...

I changed the title to reflect that the license dropdown already exists, but the
opportunity for a 2nd/3rd/etc dropdown on the upload page should be considered a
seperate request.

I envision it for categorization of the images, such as: Animals, People,
Buildings, Landscapes, etc. This would be extremely useful, especially for the
creative commons folk.

We could implement it the same was as the license dropdown
(http://en.wikipedia.org/wiki/MediaWiki:Licenses), or less user-friendly, but we
could look at my earlier suggestion in the first post.

robchur wrote:

Problem is, that's a lot of categories, which would be one hell of a performance
killer.

webmaster wrote:

No no...

I don't think an auto-generated list of categories would ever work...
Even on a small wiki, there can be dozens of categories. Which I agree would
generate an extremely ugly dropdown and a massive SQL query.

I am thinking more about a manually edited list of categories, possibly
populated by an array in LocalSettings.php.

Small wikis could choose their top 10 categories, as I listed above. The larger
wikis such as commons, could use the list to divide and prioritize image uploads
into more general topics. Such topics could be: Persons, Places, Things,
High-Importance, Low-Importance, etc.
These 'generalized' categories would at least give the creative-commons
maintenance folk something to work with. As well, it would drastically cut-down
on the number of images that are completely uncategorized.

Brand-new images may not be categorized into the most specific area, but at
least they could be found and used almost immediately.

I contend that this feature would be extensively used by all WikiMedia projects
and by a great portion of non-WikiMedia projects as well. The license dropdown
surely can attest to the success of such a software convenience.

Speaking for our 2 projects alone, this would be an invaluable addition.

webmaster wrote:

Hey Brion,

Rob has some interesting thoughts on this... I don't suppose you have any ideas
how this could be made to work, do you? Again, I am not referring to any massive
list of categories here, but rather sort of a quick-and-dirty way of organising
images into more general categories, based on a list like the Licenses.

I really think the Commons admins would love this feature...

Thanks!

webmaster wrote:

That should definitely work nicely.
Thanks Titoxd!

This functionality might still be useful for someone else, but I believe Titoxd's
solution should work for me. I would be fine if the powers-that-be wanted to
close this as wontfix...

Cheers!

ayg wrote:

No, that abuse is hacky and unacceptable as a fix for this from a software
perspective. I can't blame them for using it for lack of alternatives, though.

webmaster wrote:

Agreed, a dropdown or some other option-selector device would be more ideal, long-term.
Keep it open. ;)

webmaster wrote:

I was wrong, that solution wasn't what I was expecting.

There definitely needs to be a more proper solution for this scenario.

Clearly, Commons needs it as much as I do...

eep wrote:

Using javascript (AJAX, whatever), multiple dropdowns/listboxes could be created starting with the root/top-level categories and working their way down relative to what's selected. CategoryTree could also be integrated into the upload and edit pages to select categories for things (but it should show # of subcats too). Also, looking at the database tables, there is a LOT of repeated info in the "categorylinks" table with category/article names instead of their numeric (less bytes) IDs.

UploadWizard allows licenses and categorisation.

https://www.mediawiki.org/wiki/Extension:UploadWizard

HotCat can categorise files on upload

https://en.wikipedia.org/wiki/Wikipedia:HotCat

Is this enhancement request still necessary? If so, it probably should be part of bug 167 / bug 27312 (with one of them as a dependency for this bug).

It seems that some of the details for this feature request have changed. Currently, this option is already available for the UploadDialog in both the classic wikieditor and in visualeditor. It's quite confusing when a user sets configuration in https://www.mediawiki.org/wiki/Manual:$wgUploadDialog that it changes the dialogues in both of those editors, but not in the main upload form. This should really be an added reason to reconsider the priority of this bug and its usefulness in the eye of keeping configuration results within MediaWiki consistent as well as managing the expectations of users on what a configuration option does.

Aklapper changed the subtype of this task from "Task" to "Feature Request".Feb 4 2022, 11:01 AM
Aklapper removed a subscriber: wikibugs-l-list.