Module:Edit button

From Delanor Wiki
Jump to navigation Jump to search

-- {{#invoke:Helper module|main}} -- Creates a link that opens the editor screen for whatever page this module is invoked on

return function(text, page) local page_title = page or mw.title.getCurrentTitle().fullText local url = tostring(mw.uri.fullUrl(page_title,'action=edit')) return '['..url..' '..(text or 'edit')..']' end