Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/asp.net/31.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C#,如何获取仅获取参数?_C#_Asp.net_Get - Fatal编程技术网

C#,如何获取仅获取参数?

C#,如何获取仅获取参数?,c#,asp.net,get,C#,Asp.net,Get,System.Web.HttpContext.Current.Request.Params似乎返回了太多的参数,包括标题等。。。如何有效地仅检索GET或POST参数?对GET段落使用Request.QueryString集合,对POST段落使用Request.Form集合 e、 g 请参阅并请在MVC6请求中用一点代码详细说明。查询字符串[“YourGetPara”]变成请求。查询[“YourGetPara”] var someValueFromGet = Request.QueryString

System.Web.HttpContext.Current.Request.Params
似乎返回了太多的参数,包括标题等。。。如何有效地仅检索GET或POST参数?

对GET段落使用Request.QueryString集合,对POST段落使用Request.Form集合

e、 g


请参阅并

请在MVC6
请求中用一点代码详细说明。查询字符串[“YourGetPara”]
变成
请求。查询[“YourGetPara”]
var someValueFromGet = Request.QueryString["YourGetPara"];
var someValueFromPost = Request.Form["YourPostPara"];