How to retrieve user-agent from wxWebView(EOM)?
-
- Earned a small fee
- Posts: 14
- Joined: Wed Apr 25, 2012 2:45 am
How to retrieve user-agent from wxWebView(EOM)?
i am building a wx based application which will send HTTP request to remote sever and wondering whether can i set the user-agent more accurate?
Lisheng Guan (guanlisheng.com)
Developer of Money Manager Ex
Developer of Money Manager Ex
Re: How to retrieve user-agent from wxWebView(EOM)?
Are you referring to the "wxWidgets 2.x" user-agent that wxWidgets uses by default?
That depends on how exactly you send the HTTP request. If you have access to a wxHTTP instance, you can use:
http://docs.wxwidgets.org/trunk/classwx ... 46c7218b6e
That depends on how exactly you send the HTTP request. If you have access to a wxHTTP instance, you can use:
Code: Select all
http->SetHeader("User-Agent", "my-user-agent");
Use the source, Luke!
-
- Earned a small fee
- Posts: 14
- Joined: Wed Apr 25, 2012 2:45 am
Re: How to retrieve user-agent from wxWebView(EOM)?
Thanks and i wanted to know how to get the user-agent instead of setting.
Lisheng Guan (guanlisheng.com)
Developer of Money Manager Ex
Developer of Money Manager Ex
Re: How to retrieve user-agent from wxWebView(EOM)?
The question in the title didn't match the question in the other text.Thanks and i wanted to know how to get the user-agent instead of setting.
But i don't know a way to check your own user-agent programmatically, what for do you need it?
Manually you can check on sites like: http://www.whoishostingthis.com/tools/user-agent/
Use the source, Luke!