Namevaluecolleciton To Querystring


/ Published in: C#
Save to your folder(s)



Copy this code and paste it in your HTML
  1. private string JoinNvcToQs(NameValueCollection qs)
  2. {
  3. return string.Join("&", Array.ConvertAll(qs.AllKeys, key => string.Format("{0}={1}", HttpUtility.UrlEncode(key), HttpUtility.UrlEncode(qs[key]))));
  4. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.