Module:Sandbox/Jackmcbarn/variables/sandbox

local p = {}

function p.set(frame) frame:extensionTag{name = 'ref', content = frame.args[2], args = { group = 'lower-greek', name = frame.args[1] }} return '' end

function p.get(frame) local refText = mw.text.unstrip(frame:extensionTag{name = 'references', args = { group='lower-greek' }}) local keyMatch = mw.ustring.gmatch(refText, '') local valMatch = mw.ustring.gmatch(refText, ' ([^<]*)') local variables = {} for key in keyMatch do		variables[key] = valMatch frame:extensionTag{name = 'ref', content = variables[key], args = { group = 'lower-greek', name = key }} end return variables[frame.args[1]] end

function p.done(frame) frame:extensionTag{name = 'references', args = { group='lower-greek' }} return '' end

return p