×
Create a new article
Write your page title here:
We currently have 1,662 articles on The Quelmar Wiki. Type your article name above or click on one of the titles below and start writing!



The Quelmar Wiki
Revision as of 01:23, 10 January 2024 by Spiderjjr45 (talk | contribs) (Created page with "local p = {} -- Function to fetch and return the Worldbuilder section local function getWorldbuilderSection() local pageTitle = mw.title.getCurrentTitle().text local talkPageTitle = 'Talk:' .. pageTitle local talkPage = mw.title.new(talkPageTitle) local talkContent = talkPage:getContent() if not talkContent then return '' end local sectionPattern = '==%s*Worldbuilder%s*==(.*)' local worldbuilderSection = talkContent:match(sectio...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Documentation for this module may be created at Module:Worldbuilders/doc

local p = {}

-- Function to fetch and return the Worldbuilder section
local function getWorldbuilderSection()
    local pageTitle = mw.title.getCurrentTitle().text
    local talkPageTitle = 'Talk:' .. pageTitle
    local talkPage = mw.title.new(talkPageTitle)
    local talkContent = talkPage:getContent()

    if not talkContent then
        return ''
    end

    local sectionPattern = '==%s*Worldbuilder%s*==(.*)'
    local worldbuilderSection = talkContent:match(sectionPattern)

    if not worldbuilderSection then
        return ''
    end

    return worldbuilderSection
end

-- Automatically execute the function when the module is invoked
p = getWorldbuilderSection()

return p
Cookies help us deliver our services. By using our services, you agree to our use of cookies. (Hi Margarita's Table. 🇩🇪)
Cookies help us deliver our services. By using our services, you agree to our use of cookies. (Hi Margarita's Table. 🇩🇪)