Hi,
In the documentation for webkit on the google code page. http://code.google.com/android/reference/android/webkit/WebSettings.html#setUserAgent(int)
WebKit has a java method for setting the user agent string, and it seems that built right into the browser is the ability to set the user agent as the iphone by using setUserAgent(2). I have enough java experience to understand that it is possible, but not enough to figure out how to impliment it ATM.
Is this method only to be effective when the webview is created when the browser launches?
Can i use java script ie: javascript:void(setUserAgent(2)
to change the browsers user agent string during a currently launched webview session?
Or is there a way to modify the source of the browser so that i can create another application (ie: iphone browser) that launches a webview with the correct webkit.settings settings applied?
I'd love any push in the right direction, i've googled furriously and feel that not many people are interested in spoofing the user agent string.
You're not the only one looking for this information. I found that proxoid allows you to "spoof" your User Agent but I have't quite got that to work for me in a real situation where a site is using UA redirections. I've noticed some of the new variants of browsers like Steel and Dolphin are setup to have multiple UA's available but what I'm looking for is a way to actually modify the string that is passed. let me know if you find anything on this.
This option is included in Loccy's "BetterBrowser" found here http://forum.xda-developers.com/showthread.php?t=551119
Loccy's "BetterBrowser" comes preinstalled in Cyanogen's latest ROM, so anyone running Cyanogen's latest has this option available to them in the browser settings.
Phones: T···Mobile· Black G1
T···Mobile· Black MT4G
Firmware/SPL: 2.1/Danger SPL
Rom: Cyanogen Mod v5.0.7
Recovery: Amon RA Recovery v1.7.0
SD Card: 8gb Class 6 Apps2SD
To view links or images in signatures your post count must be 5 or greater. You currently have 0 posts.
Google Talk: ThaBadBoy
Y! Messenger: BadBoynClev
I think the only thing this is used for is rendering pages that doesn't look right on Android to be viewed on Android. I remeber a few months ago I went to certain pages and it asked me what id I was using, Android wasn't on the list but iPhone was so I selected iPhone and it worked
To view links or images in signatures your post count must be 5 or greater. You currently have 0 posts.
Check me out
To view links or images in signatures your post count must be 5 or greater. You currently have 0 posts.
To view links or images in signatures your post count must be 5 or greater. You currently have 0 posts.
To view links or images in signatures your post count must be 5 or greater. You currently have 0 posts.
Bookmarks