Skip to content

Instantly share code, notes, and snippets.

@mouseroot
Created April 24, 2014 00:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mouseroot/11236758 to your computer and use it in GitHub Desktop.
Save mouseroot/11236758 to your computer and use it in GitHub Desktop.
C# POSTDATA Parser
Dictionary<string, string> postParams = new Dictionary<string, string>();
postParams.Clear();
string[] rawParams = rawData.Split('&');
foreach (string param in rawParams)
{
string[] kvPair = param.Split('=');
string key = kvPair[0];
string value = HttpUtility.UrlDecode(kvPair[1]);
postParams.Add(key, value);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment