simple-http icon indicating copy to clipboard operation
simple-http copied to clipboard

how decide a valid post request

Open JohnsonJohnsonYuan opened this issue 7 years ago • 0 comments

"application/x-www-form-urlencoded;charset=UTF-8" is not treated as post request, simple-http cannot get values.

in RequestExtensions.Form.cs, we only treat ContentType == "application/x-www-form-urlencoded" as a valid post request, maybe we can use IndexOf method to decide?

static bool ParseForm(HttpListenerRequest request, Dictionary<string, string> args)
        {
            if (request.ContentType != "application/x-www-form-urlencoded")
                return false;

JohnsonJohnsonYuan avatar Aug 24 '18 06:08 JohnsonJohnsonYuan