Skip to content

HydraWiki/UploadFields

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

The UploadFields Extension is a MediaWiki extension which allows the configuration of custom upload fields to be added to the Special:Upload page. Information from those custom fields is then added to the template on the file page.

Project Homepage: Documentation at Github
Source Code: Source code at Github
Bugs:issues at Github
Licensing: UploadFields is GPL-2.0+ Copyright 2017 Curse

Table of Contents

Installation

Usage

To create a new upload field start by creating a new page in the MediaWiki namespace.

The format of the page name is: UploadField-field_type-Name

Valid types are:

  • select - Select drop down. Supports option groups down to two depths.
  • multiselect - Series of check boxes for multiple selection. Supports option groups down to two depths.
  • text - Single line text input.
  • textarea - Multiple line text input.
  • category - Display a multiple select drop down of existing categories on the wiki.
If you wanted a drop down HTML select field named "Game" you would create the definition page: [[MediaWiki:UploadField-select-Game]]

Field Types

select and multiselect

These two types support two levels deep of listed options which is limited due to HTML specifications. Simply make a standard unordered list up to ** deep. Any blank lines and lines not starting with * with be ignored.

Each selection value should be in the format of: TemplateValue|Label Name

* Combinations
** CE|Collector's Edition

Example: Selecting "This Amazing Game Part 1" from the "Game" field when uploading a new image would result in "Game=Part1" being added to the FileInfo template.

{{FileInfo
|Game=Part1
}}

text and textarea

The text and textarea types add their respective single line or multiple line text fields to the upload form. The content of the MediaWiki:UploadField-text(area)-Name definition page will be filled in as a default value and can be left blank.

category

The category type produces a multiple select check box list of existing wiki categories to choose from. There is no filtering and any content added to the MediaWiki:UploadField-category-Name definition page will be ignored.