nginx模塊開發獲取post參數
睿豐德科技 專注RFID識別技術和條碼識別技術與管理軟件的集成項目。質量追溯系統、MES系統、金蝶與條碼系統對接、用友與條碼系統對接
> 您好!
> 我想請問下nginx模塊里面怎么獲取post參數,能有具體的代碼更好!謝謝
>
對于 "application/x-www-form-urlencoded" 格式的 POST 參數獲取,可以參考 ngx_lua 模塊的
ngx.req.get_post_args() 函數以及 ngx_form_input 模塊的實現:
http://wiki.nginx.org/HttpLuaModule
https://github.com/calio/form-input-nginx-module
而對于 "multipart/form-data" 格式的 POST 參數獲取,可以參考 ngx_upload 模塊以及 lua-resty-upload 庫:
http://www.grid.net.ru/nginx/upload.en.html
https://github.com/agentzh/lua-resty-upload
Best regards,
-agentzh