接受POST请求的主体内容(数据流)

Stream s = System.Web.HttpContext.Current.Request.InputStream;
byte[] b = new byte[s.Length];
s.Read(b, 0, (int)s.Length);
string body = Encoding.UTF8.GetString(b);

posted @ 2021-01-29 12:31  苦逼的猿人  阅读(206)  评论(0编辑  收藏  举报