c# - ASP.NET - 如何确定用户是否是移动用户?

标签 c# asp.net mobile

我想知道浏览我网站的用户是否是移动用户。我使用了“HttpContext.Current.Request.Browser.IsMobileDevice”,但发现它毫无用处,因为在我的手机上查看该网站时它并没有反射(reflect)出我的使用情况。

是否有另一种方法可以确定用户是否是工作更好的移动用户?

我看过用户代理,它看起来很乱!

我应该指出,这与 CSS 无关,我想记录用户是否为数据库表中的移动用户。

是的,我知道谷歌分析已经可以做到这一点,但不幸的是这不是我的决定!

谢谢

最佳答案

查看

51degrees

It’s provided as a .NET open source class library that detects mobile devices and browsers, enhancing the information available to .NET programmers. Using 51Degrees.mobi Device Data, accurate screen sizes, input methods, plus manufacturer and model information are all available. Mobile handsets can optionally be redirected to content designed for mobile devices. Smart phones, tablets and feature phones are all supported.

正如评论中指出的那样。

The detection and redirection part of the product offering is free. The free trial is for their mobile optimzation products

关于c# - ASP.NET - 如何确定用户是否是移动用户?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9705838/

相关文章:

C# do..while 循环列表

asp.net - 检查 HTTP 请求查询字符串并在出现意外参数时指示错误是个好主意吗?

Qt Web 引擎 : Is there a way to emulate a mobile browser?

html - 在开发人员工具中测试响应能力时,网站 react 完美,但不是以实际手机屏幕为中心?

c# - 如何根据许多选项确定 VAR?

c# - 如何在 outlook 插件中保存登录 token

asp.net - 分层数据库选择/插入语句 (SQL Server)

c# - 如何找到两个日期之间的年月差?

android - 使用大而美观的光标录制 Android 应用程序的视频?

c# - 嵌套排除搜索中的属性