Anyone know of a way to fix this? I am using this function to detect the user agent and redirect as needed.
Code:
FUNCTION IsMobile as L(user_agent as C) dim mobile_browser as L=.f. dim mobile_agent[1] as C mobile_agent[] = "iPhone"; mobile_agent[] = "iPad"; mobile_agent[] = "Mozilla/4."; mobile_agent[] = "Mozilla/3.0"; mobile_agent[] = "AvantGo"; mobile_agent[] = "ProxiNet"; mobile_agent[] = "Danger hiptop 1.0"; mobile_agent[] = "DoCoMo/"; mobile_agent[] = "Google CHTML Proxy/"; mobile_agent[] = "UP.Browser/"; mobile_agent[] = "SEMC-Browser/"; mobile_agent[] = "J-PHONE/"; mobile_agent[] = "PDXGW/"; mobile_agent[] = "ASTEL/"; mobile_agent[] = "Mozilla/1.22"; mobile_agent[] = "Handspring"; mobile_agent[] = "Windows CE"; mobile_agent[] = "PPC"; mobile_agent[] = "Mozilla/2.0"; mobile_agent[] = "Blazer/"; mobile_agent[] = "Palm"; mobile_agent[] = "WebPro/"; mobile_agent[] = "EPOC32-WTL/"; mobile_agent[] = "Tungsten"; mobile_agent[] = "Netfront/"; mobile_agent[] = "Mobile Content Viewer/"; mobile_agent[] = "PDA"; mobile_agent[] = "MMP/2.0"; mobile_agent[] = "Embedix/"; mobile_agent[] = "Qtopia/"; mobile_agent[] = "Xiino/"; mobile_agent[] = "BlackBerry"; mobile_agent[] = "Gecko/20031007"; mobile_agent[] = "MOT-"; mobile_agent[] = "UP.Link/"; mobile_agent[] = "Smartphone"; mobile_agent[] = "portalmmm/"; mobile_agent[] = "Nokia"; mobile_agent[] = "Symbian"; mobile_agent[] = "AppleWebKit/413"; mobile_agent[] = "UPG1 UP/"; mobile_agent[] = "RegKing"; mobile_agent[] = "STNC-WTL/"; mobile_agent[] = "J2ME"; mobile_agent[] = "Opera Mini/"; mobile_agent[] = "SEC-"; mobile_agent[] = "ReqwirelessWeb/"; mobile_agent[] = "AU-MIC/"; mobile_agent[] = "Sharp"; mobile_agent[] = "SIE-"; mobile_agent[] = "SonyEricsson"; mobile_agent[] = "Elaine/"; mobile_agent[] = "SAMSUNG-"; mobile_agent[] = "Panasonic"; mobile_agent[] = "Siemens"; mobile_agent[] = "Sony"; mobile_agent[] = "Verizon"; mobile_agent[] = "Cingular"; mobile_agent[] = "Sprint"; mobile_agent[] = "AT&T;"; mobile_agent[] = "Nextel"; mobile_agent[] = "Pocket PC"; mobile_agent[] = "T-Mobile"; mobile_agent[] = "Orange"; mobile_agent[] = "Casio"; mobile_agent[] = "HTC"; mobile_agent[] = "Motorola"; mobile_agent[] = "Samsung"; mobile_agent[] = "NEC"; for i=1 to mobile_agent.size() dim cur_agent as C=mobile_agent[i] if atc(cur_agent,user_agent)>0 then mobile_browser=.t. exit for end if next IsMobile=mobile_browser END FUNCTION