From: Steven Barth Date: Fri, 18 Jul 2008 20:53:45 +0000 (+0000) Subject: libs/web: Fixed a bug regarding % characters in luci.template X-Git-Tag: 0.8.0~621 X-Git-Url: http://git.openwrt.org/?a=commitdiff_plain;h=90c98540b15d2f780fc30223e6ff32399a78a130;p=project%2Fluci.git libs/web: Fixed a bug regarding % characters in luci.template --- diff --git a/libs/web/luasrc/template.lua b/libs/web/luasrc/template.lua index 5647865f7a..18abf6df81 100644 --- a/libs/web/luasrc/template.lua +++ b/libs/web/luasrc/template.lua @@ -93,6 +93,7 @@ function compile(template) -- Parse the expressions for k,v in pairs(expr) do local p = v:sub(1, 1) + v = v:gsub("%%", "%%%%") local re = nil if p == "+" then re = r_include:format(sanitize(string.sub(v, 2)))