How does Request.Browser["IsMobileDevice"] do its work? The only information that the server has still has to come from the HTTP headers and they are retrieveable from Request.ServerVariables["ALL_RAW"].
How does it catch up with new browsers that come up after the .NET Framework has been released?
I scanned through all the browsers that hit my web server, and it looks like all mobile browsers except one has a non-null
x-wap-profile in Request.ServerVariables. Testing for the presence of this would give a good indication that it is a phone browser. The one exception is the iPhone. It does not have this field. The word "iPhone" is in the user agent field.
But it is still hardcoding.
Member
82 Points
238 Posts
Re: How to detect Mobile devices like Pocket PC??
Oct 01, 2008 11:54 AM|hc1|LINK
How does Request.Browser["IsMobileDevice"] do its work? The only information that the server has still has to come from the HTTP headers and they are retrieveable from Request.ServerVariables["ALL_RAW"]. How does it catch up with new browsers that come up after the .NET Framework has been released?
I scanned through all the browsers that hit my web server, and it looks like all mobile browsers except one has a non-null x-wap-profile in Request.ServerVariables. Testing for the presence of this would give a good indication that it is a phone browser. The one exception is the iPhone. It does not have this field. The word "iPhone" is in the user agent field. But it is still hardcoding.
hc