Open main menu
Home
Random
Donate
Recent changes
Special pages
Community portal
Preferences
About Stockhub
Disclaimers
Search
User menu
Talk
Contributions
Create account
Log in
Editing
Module:Sandbox/Erutuon/random
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
local p = {} local Out_mt = {} Out_mt.__index = Out_mt function Out_mt:add(...) for i = 1, select('#', ...) do self.i = self.i + 1 self[self.i] = select(i, ...) end end function Out_mt:__tostring() return table.concat(self) end function Out() local o = setmetatable({}, Out_mt) o.i = 0 return o end function p.show(frame) local out = Out() local language_data = require 'Module:Language/data' local Wiktionary = { name_to_code = require 'Module:Language/Wiktionary name to code', code_to_name = require 'Module:Language/Wiktionary code to name', } for code, data in require 'Module:TableTools'.sortedPairs(language_data.languages) do if not Wiktionary.code_to_name[code] then out:add(code) local Wiktionary_code = data.name and Wiktionary.name_to_code[data.name] if Wiktionary_code then out:add(' → ', Wiktionary_code) local MediaWiki_name = mw.language.fetchLanguageName(Wiktionary_code, 'en') if MediaWiki_name ~= data.name then out:add(' (MediaWiki: ', MediaWiki_name ~= '' and MediaWiki_name or '<none>', ', Wiktionary: ', data.name, ')') end end out:add('\n* ') elseif data.name and data.name == mw.language.fetchLanguageName(code, 'en') then out:add(code, ' (', data.name, ')') out:add('\n* ') end end return out end return p
Summary:
Please note that all contributions to Stockhub may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Stockhub:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Templates used on this page:
Module:Language/Wiktionary name to code
(
edit
)
Module:Language/data
(
edit
)
Module:Sandbox/Erutuon/random
(
edit
)
Module:Sandbox/Erutuon/random/doc
(
edit
)