Edge Rewrite
// HTMLRewriter · presentation

This page was redesigned at the edge.

Cloudflare fetched the original article and streamed it through HTMLRewriter to apply an entirely new visual system without rebuilding the source page.

Jump to content

Module:Sandbox/TheThomanski/Esc

From Wikipedia, the free encyclopedia
local getArgs = require('Module:Arguments').getArgs
local p = {}

function p.entry(f)
	local args = getArgs(f)
	
	local contest   = args[1]
	local year      = args[2]
	local entry     = args[3]
	local attribute = args[4]
	
	local contest = mw.loadData('Module:Sandbox/TheThomanski/Esc/data/'..contest..'/'..year)

    local result = ""
	for k, v in pairs(contest[entry]) do
		if (k == attribute) then
			result = v
			break
		end
	end
	return result
end

return p