views:

54

answers:

2

Hi all,

I am developing a small application in Android. I come across a problem, and not sure whether it is possible in Android platform.

I have some local html files. There is an Activity contains a webview, which is used to display these local html files. In some cases, I want to display a picture selected from phone into one of these local html files.

Is it possible? Has anyone resolved such problem? I appreciate any of your replies.

Best

A: 

Have you tried using the appropriate content:// URL in your <img> tag, pointing to the "picture selected from phone"?

CommonsWare
Haven't yet, could you please give me some more hints? So I can figure it out by myself. What is looks like after content://?
Kavin
You claim to have gotten a "picture selected from phone". If you are really doing that, you should have gotten a `Uri` object. Calling `toString()` on that `Uri` will give you the `content://` URL in string form, suitable for injecting into a Web page.
CommonsWare
A: 

check out this article... it might help :)

http://developerlife.com/tutorials/?p=369

optimystery
This is a really good tutorial. Thank you
Kavin