X-Git-Url: https://git.archive.openwrt.org/?a=blobdiff_plain;f=modules%2Fluci-base%2Fluasrc%2Fview%2Fcbi%2Fvalue.htm;h=c43dab5f4b49373a6368686d6f812f28afd48091;hb=3a58ef46c279ba4a72c21b81256877c16444b9fb;hp=6e05206aa1ba4e6c58423d9ee98cf5a57376b60d;hpb=c7d3619b0ca0a05251ddbfff0c49f45247346de2;p=project%2Fluci.git diff --git a/modules/luci-base/luasrc/view/cbi/value.htm b/modules/luci-base/luasrc/view/cbi/value.htm index 6e05206aa..c43dab5f4 100644 --- a/modules/luci-base/luasrc/view/cbi/value.htm +++ b/modules/luci-base/luasrc/view/cbi/value.htm @@ -1,7 +1,8 @@ <%+cbi/valueheader%> /> <% if self.password then %><% end %> <% if #self.keylist > 0 or self.datatype then -%> @@ -28,7 +29,7 @@ <%- end -%>'); <%- end %> <% if self.datatype then -%> - cbi_validate_field('<%=cbid%>', <%=tostring((self.optional or self.rmempty) == true)%>, '<%=self.datatype:gsub("'", "\\'")%>'); + cbi_validate_field('<%=cbid%>', <%=tostring((self.optional or self.rmempty) == true)%>, '<%=self.datatype:gsub("\\", "\\\\"):gsub("'", "\\'")%>'); <%- end %> //]]> <% end -%>