return url in wiki.lua

This commit is contained in:
Akamaru 2015-06-17 22:58:05 +02:00
parent 30dcf34395
commit 42af2212d0

View File

@ -101,10 +101,10 @@ function Wikipedia:wikintro(text, lang)
if page and page.extract then if page and page.extract then
local lang = lang or "de" local lang = lang or "de"
return text..":\n"..page.extract.."\n -- https://"..lang..".wikipedia.org/"..text local title_enc = URL.escape(page.title)
return text..":\n"..page.extract.."\n -- https://"..lang..".wikipedia.org/wiki/"..title_enc
else else
local text = "Extract nicht gefunden für: "..text local text = '"'..text..'" nicht gefunden.'
text = text..'\n'..table.concat(wikiusage, '\n')
return text return text
end end
else else