用户 - 代理ios 5.0?

时间:2011-10-20 09:31:26

标签: iphone webview user-agent

  

可能重复:
  What is the iOS 5.0 user agent string?

我想在网络视图中使用移动页面

所以,我认识到设备(= iphone)

3gs iost 5.0。什么用户代理?

NSMutableURLRequest * request =(NSMutableURLRequest *)req;

 if ([request respondsToSelector:@selector(setValue:forHTTPHeaderField:)]) 
 { 

[request setValue:[NSString stringWithFormat:@“%@ Mozilla / 5.0
   (iPhone; CPU iPhone OS 5_0,如Mac OS X)AppleWebKit / 534.46(KHTML,如Gecko)版本/ 5.1 Mobile / 9A334 Safari / 7534.48.3
“,[请求valueForHTTPHeaderField:@”User-Agent“]] forHTTPHeaderField:@ “User_Agent类”];     }     返回YES; }

大胆的区域。我想要一个正确的用户代理。

1 个答案:

答案 0 :(得分:0)

iOS 5.0

iPhone:

Mozilla/5.0 (iPhone; CPU iPhone OS 5_0 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9A334 Safari/7534.48.3

ipad公司:

Mozilla/5.0 (iPad; CPU OS 5_0 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9A334 Safari/7534.48.3

iOS 5.1

iPhone:

Mozilla/5.0 (iPhone; CPU iPhone OS 5_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9B176 Safari/7534.48.3

ipad公司:

Mozilla/5.0 (iPad; CPU OS 5_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9B176 Safari/7534.48.3