UIWebView在运行时设置用户代理 [英] UIWebView set user-agent at run time
本文介绍了UIWebView在运行时设置用户代理的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
可能重复:
UIWebView iOS5更改用户代理
需要打开某些桌面版本的网站和某些移动版本的网站.如何在UIWebView的委托'webView:shouldStartLoadWithRequest:navigationType'中设置其他用户代理.预先感谢.
There is requirement to open some website in desktop version and some in mobile version. how to set different user agent in UIWebView's delegate 'webView:shouldStartLoadWithRequest:navigationType'. Thanks in advance.
推荐答案
请参阅引用 iphone-ipad-get-user-agent-for-uiwebview 链接
还请参考 uiwebview-ios5-changing-user-agent SO链接.
这篇关于UIWebView在运行时设置用户代理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文