Patching CGILua to handle
CGILua 5.0 does not accept
text/plain content, and will generate an error of 'Unsupported Media Type: text/plain'.
This is easily patched in CGILua 5.0 by making the following change to
cgilua/post.lua, line 286:
elseif strfind (contenttype, "text/xml") then
elseif strfind (contenttype, "text/xml") or strfind (contenttype, "text/plain") then
This makes CGILua handle
text/plain as it does
text/xml, without parsing the incoming POST data.
Please note: I have requested the maintainers of CGILua to make this change to CGILua, whereafter this patch will no longer be required.