最近在做移动端网站,也需兼容PC端.还没找到更好的方法,只能用javascr判断用户是在PC端打开还是移动端打开. JS判断 var isPC = function (){ var userAgentInfo = navigator.userAgent.toLowerCase(); var Agents = new Array("android", "iphone", "symbianOS", "windows phone&
using Microsoft.AspNetCore.Http;using System;using System.Collections.Generic;using System.Text;using System.Text.RegularExpressions; namespace Niunan.BamaTZ.Web.Models{ public static class RequestExtensions { //regex from http://detectm