On Wed, Mar 14, 2012 at 1:46 PM, David Karr <[email protected]> wrote: > I know that an Android app can get the phone model and phone number, but > what has to be in place for Javascript in a webapp, running in the Android > browser, to get the same information. I know that I could have an Android > app that creates a WebView, but is it possible for a webapp running in the > stock browser to have access to that info?
First, there is no "the Android browser". There are probably as many browsers for Android as there are for Windows. I assume you mean the stock AOSP browser, which will exist on most but not all devices. Second, unless there is some W3C standard for privacy leaks, I hope a Web browser never has the ability to get the device's phone number, or at least it is disabled by default. Heck, we can't even get that reliably from *Java*. Model information may be included as part of the User-agent HTTP header, so navigator.userAgent or navigator.appVersion in theory should be able to provide that to you. Whether any given browser provides model information, of course, is up to that browser maker. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

