C#, how to get only GET parameters?

System.Web.HttpContext.Current.Request.Params seems to return way too many params, including headers, etc... How can I efficiently only retrieve GET or POST parameters ?


use Request.QueryString Collection for GET paras and Request.Form Collection for POST ones.


var someValueFromGet = Request.QueryString["YourGetPara"];
var someValueFromPost = Request.Form["YourPostPara"];

please refer to http://msdn.microsoft.com/en-us/library/ms524784(v=vs.90).aspx and http://msdn.microsoft.com/en-us/library/ms525985(v=vs.90).aspx

Need Your Help

'ansible_date_time' is undefined

amazon-web-services amazon-ec2 ansible ansible-playbook

Trying to register an ec2 instance in AWS with Ansible's ec2_ami module, and using current date/time as version (we'll end up making a lot of AMIs in the future).

How to implement Google doc like text editor?

javascript html css

I opened a google doc, it seems that the google doc is not a simple text area .... it seems that this is a customize stuff.... is there any library for doing that kind of things?