Titanium Community Questions & Answer Archive

We felt that 6+ years of knowledge should not die so this is the Titanium Community Questions & Answer Archive

Using images in Inline HTML for a webview

Hello,
I am trying to use images (thru <img> html tag) on inline html to be displayed thru a webview.

I can't figure out the proper way path to access the image, I think I have tried all possible combinations
and the image always fails to display on the rendered webview. Any ideas ?

Thank you,
JS

— asked April 3rd 2010 by JS -
  • html
  • image
  • inline
  • webview
0 Comments

2 Answers

  • Accepted Answer

    Hi there.

    This format should work:

    <img src="app://images/logo.png" alt="logo">

    cheers,
    Chris.

    — answered April 4th 2010 by Chris Reed
    permalink
    0 Comments
  • Thanks a lot for the quick answer Chris, but it does not seem to work for me :( I have tried using the app:// url pointing to different paths, and copying my image in different places, without success. I'm always getting an image not found "image" in the webview.
    I'm using Titanium Mobile SDK 1.1.2, for Android, APIs 2.1
    Is anyone else having a similar issue ?

    Thank you,
    JS

    — answered April 4th 2010 by JS -
    permalink
    0 Comments
The ownership of individual contributions to this community generated content is retained by the authors of their contributions.
All trademarks remain the property of the respective owner.