开发者

User Agent in http client Android

I building an Https Client to send some data to a server, but I don't know what to pass in User-Agent. Should I use the webkit one's or do I have to build开发者_Python百科 one explicitely for my App? I'm using this handy post Thanks for any help


You don't need to pass any User-Agent header, unless you're using a service that explicitly requires it such as for tracking or debugging purposes etc.

HTTP works perfectly well without the User-Agent header being present.


you can send: "Mozilla/5.0 (Linux; U; Android 1.0; en-us; generic) AppleWebKit/525.10+ (KHTML, like Gecko) Version/3.0.4 Mobile Safari/523.12.2" that's emulator user agent string

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜