Hello!
On Thu, Aug 21, 2014 at 12:30 AM, Prashant Gaur wrote:
> - Example :
>
> content1 = "HiTestHello Test how are you Testall "
> _ssi = "Test"
> body = "$100.00"
> content2 = ngx.re.gsub(content1, _ssi, body)
> ngx.print(content2)
>
https://github.com/openresty/lua-nginx-module#ngxresub
"Literal dollar sign characters ($) in the replace string argument can
be escaped by another dollar sign, for instance,
local newstr, n, err = ngx.re.sub("hello, 1234", "[0-9]", "$$")
-- newstr == "hello, $234"
-- n == 1
Do not use backlashes to escape dollar signs; it will not work as expected."
Regards,
-agentzh