![]() | This is a documentation subpage for Template:MediaWiki file. It may contain usage information, categories and other content that is not part of the original template page. |
Usage
editThis template is a typing aid that creates a link to a MediaWiki source file.
Parameters
edit- The only parameter is an unnamed parameter
|1=
which takes the base name of the file. The base name is the filename without the filename extension.
- For example,
{{MediaWiki file|Parser}}
forParser.php
, not{{MediaWiki file|Parser.php}}
.
- For example,
- The first character is automatically capitalized; if the source file name uses camel case, such as
LocalSettings.php.php
, then the parameter must use the same case.
- If the filename is not defined, then the output will still display the given content, but will direct to the root of the MediaWiki master files. For example,
Parsoid.php.php
does not exist, but will lead to the root.
Examples
editMarkup | Renders as |
---|---|
{{MediaWiki file}} |
|
{{MediaWiki file|sanitizer}} |
|