protected void mobileRedirect()
{
string userAgent = Request.UserAgent;
bool isPC = true;
string[] Agents = new string[] { "Android", "iPhone", "SymbianOS", "Windows Phone", "iPad", "iPod" };
for (int i = 0; i < Agents.Length; i++)
{
if (userAgent.IndexOf(Agents[i]) > -1)
{
isPC = false;
}
}
if (!isPC)
{
Response.Redirect("/wap/index_mo.html");
}
}
该方法能检测出所有的移动设备吗?