handlers/render.lua

changeset 15
82d254b8f01e
parent 7
038275cd92ed
child 16
e377590e9b19
equal deleted inserted replaced
14:bbf5bbd72f48 15:82d254b8f01e
86 function handlers_render.render(file, env, path_prefix) 86 function handlers_render.render(file, env, path_prefix)
87 local data=env.pages[file].data 87 local data=env.pages[file].data
88 if data then 88 if data then
89 local newenv=handlers_render.env_for(file, env, path_prefix) 89 local newenv=handlers_render.env_for(file, env, path_prefix)
90 local data2=handlers_render.process_lua(data, newenv) 90 local data2=handlers_render.process_lua(data, newenv)
91 return markdown(data2) 91 meta=env.pages[file].meta
92 if meta.markdown == nil or meta.markdown == "true" then
93 return markdown(data2)
94 else
95 return data2
96 end
92 end 97 end
93 end 98 end
94 99
95 function handlers_render.phase2(file, env) 100 function handlers_render.phase2(file, env)
96 local page=env.pages[file] 101 local page=env.pages[file]

mercurial