Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Thaina · Apr 12, 2014 at 06:20 AM · iosiphonewwwipad

WWW in iOS does not set user agent header

I use WWW class to send event statistic. But it seem like it not sent user agent header (which I want to collect) in iOS

Is it true that it not sent?

Is it a bug? Would it be fixed?

If I need to use HashTable, how can I get user agent string from system or construct it programmatically? I don't want to switch case by my own

Thanks for your answer

Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image cregox · Apr 14, 2014 at 02:32 PM 0
Share

I'm not sure what you need, but seems like you need to improve your "google fu". There are lots of related questions there, one of which is most likely sure to be your question and thus this must be a duped question. Here are few of them: http://answers.unity3d.com/questions/468412/webclient-headers-not-showing-in-ios-build.html , http://answers.unity3d.com/questions/303702/wwwresponseheaders-or-wwwerror-are-not-working-on.html and even "outside" http://stackoverflow.com/questions/18704334/xcode-cant-find-header-files-in-unity3d-project

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Bunny83 · Apr 14, 2014 at 03:22 PM

The user agent header (rfc2616) is only ment for the client software (the user agent, in your case the Unity player) to identify itself. There is no "valid standard" which tells what the header field has to contain. Most browsers include, beside their product name, things like their html renderer, operating system / hardware, ... but that's by no means a requirement since the header is even optional.

There is no "User Agent" header for the system since, again, it describes the client software. If you need this header to distinguish between iOS / Android / standalone... you have to setup your own.

Here's a list of common User Agent headers just to get a glimpse of how many different agent-strings are out there.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Thaina · Dec 13, 2014 at 06:11 PM 0
Share

In android there are always useragent sent from WWW class of unity

And even in ios native there are also UIWebView class which can tell useragent too

Only when we use unity in ios there are no useragent sent from WWW

Useragent can tell the operating system, os version, device model and so on. It is important for collect analytics or separate platform serving content

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

23 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

WWW error on ios 1 Answer

Unity modules for iOS? 1 Answer

iPhone Controller Asset 0 Answers

iOS: Handheld.PlayFullScreenMovie 2 Answers

How to drag a scrollView with TouchPhase.Moved? 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges