I need to detect if an iPhone entering my application is an original iPhone (one of the first iPhones to be sold)
I know that this line will detect iPhones:
if (Request.UserAgent.ToUpper().Contains("IPHONE"))
{
//Do something
}
But I want to make sure that I get the correct one. I was thinking about something like this:
if (Request.UserAgent.ToUpper().Contains("IPHONE"))
{
if (double.Parse(Request.Browser.Version) > 1)
{
//Do Something
}
}
But I am worried that there could be other iPhones that are newer and are version 1.
Is this code correct for finding very old iPhones, or is there a better way?