Module:Graph: Difference between revisions

Content deleted Content added
latest version: formattable text marks also extended to bar charts
updated to latest
Line 1:
-- ATTENTION: Please edit this code at https://de.wikipedia.org/wiki/Modul:Graph
-- version 2016-01-09 _PLEASE UPDATE when modifying anything_
-- This way all wiki languages can stay in sync. Thank you!
--
-- Version History:
-- version 2016-01-09 _PLEASE UPDATE when modifying anything_
-- 2016-01-28 For maps, always use wikiraw:// protocol. https:// will be disabled soon.
 
local p = {}
 
Line 122 ⟶ 128:
-- get map url
local basemapUrl
if (string.sub(basemap, 1, 710) == "httpwikiraw://") or (string.sub(basemap, 1, 8) == "https://") or (string.sub(basemap, 1, 2) == "//") then
basemapUrl = basemap
else
-- if not a (supported) url look for a colon as namespace separator. If none prepend default map directory name.
if not string.find(basemap, ":") then basemap = baseMapDirectory .. basemap end
basemapUrl = "wikiraw:///" .. mw.uri.encode(mw.title.new(basemap):fullUrl(.prefixedText, "action=rawPATH")
end