Module:Shortcut: Difference between revisions

Jump to navigation Jump to search
96 bytes removed ,  15 December 2014
use wikilinks rather than URLs, as it would change the redlink behaviour, and that's better done after it is discussed
(allow output if no shortcuts are set but msg is present)
(use wikilinks rather than URLs, as it would change the redlink behaviour, and that's better done after it is discussed)
Line 73: Line 73:
:tag('ul')
:tag('ul')
for i, shortcut in ipairs(shortcuts) do
for i, shortcut in ipairs(shortcuts) do
local url = mw.uri.fullUrl(shortcut, {redirect = 'no'})
shortcutList:tag('li'):wikitext(string.format(
url = tostring(url)
'[[%s]]',
local link = string.format('[%s %s]', url, shortcut)
shortcut
shortcutList:tag('li'):wikitext(link)
))
end
end
if options.msg then
if options.msg then
Cookies help us deliver our services. By using our services, you agree to our use of cookies.

Navigation menu