Getting Started with Adobe After Effects - Part 6: Motion Blur
A collection of quick technology learning tips from what people around you learn every day

ASP.NET - Detecting whether the request came from ipad or not

Dec 27 2011 10:46AM by Ramireddy   

In my previous post, I showed how to find whether the request came from Mobile or PC. But later my requirement is extended to find whether the request came from IPAD or not also. For this. We can use Request.UserAgent, If it has the word "ipad", it means request came from IPAD.

if (HttpContext.Current.Request.UserAgent.ToLower().Contains("ipad"))
            DeviceInfo = "IPAD";            
Read More..   [32134 clicks]

Published under: Microsoft .NET Tips ·  ·  ·  · 


Ramireddy
2 · 40% · 12972
14
 
2
 
12
 
 
 
0
Forgotten



Submit

3  Comments  

  • Be aware that this can be easily spoofed

    https://addons.mozilla.org/en-US/firefox/addon/user-agent-switcher/

    commented on Dec 27 2011 11:08AM
    mbova407
    322 · 0% · 132
  • Oh... Thank you for caution...

    Do we have any other better alternative?

    commented on Dec 27 2011 11:23AM
    Ramireddy
    2 · 40% · 12972
  • Yes we have,MobileESP code libraries,of course it's free!

    commented on Dec 27 2011 11:37AM
    Robert Dennyson
    11 · 14% · 4420

Your Comment


Sign Up or Login to post a comment.

"ASP.NET - Detecting whether the request came from ipad or not" rated 5 out of 5 by 14 readers
ASP.NET - Detecting whether the request came from ipad or not , 5.0 out of 5 based on 14 ratings
    Copyright © Rivera Informatic Private Ltd Contact us      Privacy Policy      Terms of use      Report Abuse      Advertising      [ZULU1097]