Module:Testing: Difference between revisions
From RuneTails
Created page with "local p = {} local categories = { Fish = { 'Bass', 'Bass (Diamond)', 'Bass (Gold)', 'Bass (Jade)', 'Bass (Ruby)' }, Vegetable = { 'Beetroot', 'Carrot', 'Cave Beetroot', 'Cave Carrot', 'Cave Daikon' }, SmallVegetable = { 'Raddish', 'Spring Onion' }, Berry = { 'Abyss Berry', 'Black Berry', 'Bliss Berry', 'Blue Berry', 'Brown Berry' }, Mushroom = { 'Amber Peak', 'Aqua Polka-Dot Delight', 'Azure Whi..." |
Replaced content with "local p = {} function p.getFilename(frame) local url = frame.args[1] or "" return mw.ustring.match(url, ".+/([^/]+)$") or url end return p" Tag: Replaced |
||
| Line 1: | Line 1: | ||
local p = {} | local p = {} | ||
function p.getFilename(frame) | |||
local url = frame.args[1] or "" | |||
return mw.ustring.match(url, ".+/([^/]+)$") or url | |||
function p. | |||
local | |||
end | end | ||
return p | return p | ||
Revision as of 02:02, 13 February 2025
Documentation for this module may be created at Module:Testing/doc
local p = {}
function p.getFilename(frame)
local url = frame.args[1] or ""
return mw.ustring.match(url, ".+/([^/]+)$") or url
end
return p