r.content_type = "text/html"
local args = r:parseargs()
- local pattern = string.gsub(args.pattern, '+', ' ')
+ local pattern = args.pattern
if pattern then
+ -- filename might have spaces that apache replaces with '+'
+ pattern = string.gsub(pattern, '+', ' ')
+
local nonce = publish(r.context_document_root, pattern)
if nonce == "" then
r:puts( "No links created" )