WebView won't load local images

Discussion in 'iOS Programming' started by cmezak, Mar 17, 2009.

  1. cmezak macrumors member

    Jun 4, 2006
    Hello all,

    I'm working with a webView that loads an HTML string with a base url that is a fileURL to the bundle's resource path. The html references images like

    <img src="image5.png">
    The images are there. In fact, the images load fine in the simulator. However, on the device they do not. The webView displays the blue question mark box indicating that it can't find the images.

    Anybody know why this would be happening in device builds?


    - Charlie
  2. cmezak thread starter macrumors member

    Jun 4, 2006

    I have no idea why, but converting the files (images) to another format and then back to png is what solved the problem. Whe a formatting issue would prevent the images from being copied to the .app package, I have no clue.

    - Charlie

Share This Page