码迷,mamicode.com
首页 > Windows程序 > 详细

C# Post方式下,取得其它端传过来的数据

时间:2017-03-30 16:03:51      阅读:277      评论:0      收藏:0      [点我收藏+]

标签:eth   equals   log   als   json   res   method   c#   class   

       // Post方式下,取得java端传过来的数据
        if ("post".Equals(context.Request.HttpMethod.ToLower()))
        {
            context.Response.ContentType = "application/json";

            StreamReader reader = new StreamReader(context.Request.InputStream);

            string json = HttpUtility.UrlDecode(reader.ReadToEnd());

            context.Response.Write(json);

            context.Response.End();

            return;
        }

 

C# Post方式下,取得其它端传过来的数据

标签:eth   equals   log   als   json   res   method   c#   class   

原文地址:http://www.cnblogs.com/math3/p/6646532.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!