C# 读取QueryString全部数据并输出
using System.Collections; using System.Collections.Specialized; ... NameValueCollection collection = Request.QueryString; String[] keyArray = collection.AllKeys; Response.Write("Keys:"); foreach (string key in keyArray) { Response.Write(" " + key +": "); String[] valuesArray = collection.GetValues(key); foreach (string myvalue in valuesArray) { Response.Write("\""+myvalue + "\" "); } }