ngx.log(ngx.ERR, "cookie a:", ngx.var.cookie_a) ngx.header['Set-Cookie'] = {'a=32; path=/ ', 'b=4; path=/'} ngx.header['Content-Type'] = "text/html; charset=utf-8"; local session = require"resty.session".start() ngx.log(ngx.ERR, "cookie a:", ngx.var.cookie_a) session.data.name = "OpenResty Fan" session.cookie.path = "/123" session:save() ngx.say("

123Hello,world 中国

")