I've tried to Array Input example, and output the converted table in json format:
local resty_post = require 'resty.post'
local post = resty_post:new()
local _pdata = post:read()
ngx.say(cjson.encode(_pdata))
Output:
{"name[0]":"Bar","name[1]":"Foo","users[0][name]":"Jane Do","users[0].title":"Mr.","user[name]":"Foo Bar","users[0].name":"John Do","users[0][title]":"Ms.","user.title":"Mr."}
What's wrong ?
I've tried to Array Input example, and output the converted table in json format:
local resty_post = require 'resty.post'
local post = resty_post:new()
local _pdata = post:read()
ngx.say(cjson.encode(_pdata))
Output:
{"name[0]":"Bar","name[1]":"Foo","users[0][name]":"Jane Do","users[0].title":"Mr.","user[name]":"Foo Bar","users[0].name":"John Do","users[0][title]":"Ms.","user.title":"Mr."}
What's wrong ?