DeviceName Property

 

Type: String

 

Returns the product name of the type of mobile device. For example, "iPhone", "iPod Touch", "iPad", "Pre", "Droid", "Nexus One", "Pixi", and "Blackberry".

 

Example:

 

<%

   set bhObj = Server.CreateObject("cyScape.browserObj")

   if browObj.DeviceName = "iPhone"  then

      Response.Redirect "http://iphone.mysite.com/"

  elseif browObj.DeviceName = "iPod Touch"  then

      Response.Redirect "http://itouch.mysite.com/"

  elseif browObj.DeviceName = "iPad"  then

      Response.Redirect "http://ipad.mysite.com/"

  elseif browObj.DeviceName = "Droid"  then

      Response.Redirect "http://droid.mysite.com/"

  elseif browObj.DeviceName = "Blackberry"  then

      Response.Redirect "http://blackberry.mysite.com/"

  elseif browObj.DeviceName = "pre"  then

      Response.Redirect "http://palmpre.mysite.com/"

  elseif browObj.DeviceName = "Pixi"  then

      Response.Redirect "http://pixi.mysite.com/"

  elseif browObj.DeviceName = "Nexus One"  then

      Response.Redirect "http://nexusone.mysite.com/"

  elseif browObj.MobileDevice = true  then

      Response.Redirect "http://othermobile.mysite.com/"

  end if

%>

 

See Also:

MobileDevice Property

DeviceType Property

Detecting Mobile Devices