Munurin millum rættingarnar hjá "Module:File link/doc"
Content deleted Content added
EileenSanda (kjak | íkøst) Stovnaði síðu við "This module is used to construct wikitext links to files. It is primarily useful for templates and modules that use complicated logic to make file links. Simple file links..." |
s Bot: Erstatt forældet <source> -tag og parameteren "enclose" [https://lists.wikimedia.org/pipermail/wikitech-ambassadors/2020-April/002284.html] |
||
Linja 9:
First, you need to import the module.
<
local mFileLink = require('Module:File link')
</syntaxhighlight>
Then you can make file links using the <code>_main</code> function.
<
mFileLink._main(args)
</syntaxhighlight>
<var>args</var> is a table of arguments that can have the following keys:
Linja 43:
With the file only:
<
mFileLink.main{file = 'Example.png'}
-- Renders as [[File:Example.png]]
</syntaxhighlight>
With format, size, link and caption options:
<
mFileLink.main{
file = 'Example.png',
Linja 58:
}
-- Renders as [[File:Example.png|thumb|220px|link=Wikipedia:Sandbox|An example.]]
</syntaxhighlight>
With format, size, and border:
<
mFileLink.main{
file = 'Example.png',
Linja 69:
}
-- Renders as [[File:Example.png|frameless|border|220px]]
</syntaxhighlight>
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox||
|