Can I use img src="file:///data/data/pkg/files/xxx.png" in the webwiew?

by Philip » Wed, 29 Apr 2009 15:04:23 GMT


Sponsored Links
 Hello,

Because of some specific reason...

My application has make a copy of the img files form the assets folder
to the /data/data/pkg/files/ folder.

(ps. Actually I hope to copy the files to a cache folder, but anyway,
the data folder is fine.)

I need my webview to access the img file form the data folder.

However, I always get file for this execution.

Can any one tell me how to do this?

If anyother suggestion will be appreciate.

Thankx a lot.

Philip Chen


--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. Android 2.0: Browser/WebView can no longer load fonts?

Hi,

I have a web page that uses a custom font, using this CSS piece of
code:

    @font-face {
        font-family: "myfont";
        src: url('../../fonts/myfont.ttf');
    }

    .myclass {
        font-family: 'myfont';
    }

If I load the page in the browser in Android 1.1, 1.5 or 1.6, this
technique works fine, the font is downloaded and used.
But these were the good times.
Now this is all gone.
With 2.0 my declaration is ignored, the default font is used, and I'm
sad!

This is in the Browser app, and in my app that uses a WebView :(

Is this a known new limitation?

Thanks!
--~--~---------~--~----~------------~-------~--~----~

2. Connection dropped / app sleep on device standby?

Hey Guys,

I am looking for some help. I am seeing something odd happening when
my device goes to sleep (Hero) when the device sleeps a process which
I have in the background seems to stop picking up data from it's
server. I can't work out of the service is going to sleep or if the
network connection is being dropped (3G & WifI) can anyone shed some
light on the status of the phone when it goes into standby mode (the
user presses the power button)? What happens if a thread that is
currently sleeping wakes up and makes a network request for example?

Thanks in advance,

Tom
--~--~---------~--~----~------------~-------~--~----~

3. Accessing contact's phone number

4. Accessing contact's phone number

5. Is Orientation Sensor a Phyiscal Sensor Different from the Accelerometer?

6. My appwidget broken Donut when keyboard slide out/in

7. How does Log.isLoggable() work?