Images are not displayed

26 views
Skip to first unread message

Sebastian Roming

unread,
Mar 29, 2011, 11:24:31 AM3/29/11
to jqt...@googlegroups.com
Hi everybody,

i have an application that uses images as content.
There are twelve images each inside a div (#page_1 -> #page_12).

But when I launch the application on an iPad, sometimes some images are missing.
Some pages are displayed ok, but it could be that some pages are not
displayed and just a placeholder (on iPad the white questionmark on
blue ground) is displayed.

Every single image is in the list of preloading images.


Any ideas to fix this?

Oliv

unread,
Mar 30, 2011, 4:02:31 AM3/30/11
to jQTouch
Hi,

Becareful, maybe it's due to the safari cache... try to reduce images
size, and prefer png to jpg.

Good luck.

On 29 mar, 16:24, Sebastian Roming <sebastian.rom...@googlemail.com>
wrote:

Sebastian Roming

unread,
Mar 30, 2011, 5:23:43 AM3/30/11
to jqt...@googlegroups.com
Images are ~500kb and they are already PNG.

Sebastian Roming

unread,
Apr 3, 2011, 10:41:32 AM4/3/11
to jqt...@googlegroups.com
No ideas how to fix that Problem? :(
All images are full-sized 1024x768px, PNG files.

Sebastian Roming

unread,
Apr 4, 2011, 11:42:34 AM4/4/11
to jqt...@googlegroups.com
Yep they are packed with the App.
I have added them into a div container (that is set to
"display:none"), so that they are all loaded on startup. Is this the
right thinking?

The preloading code is as following:

var jQT = new jQuery.jQTouch({
debug: false,
preloadImages: [
'images/background.jpg',
'images/iPad_1/de/page_1.jpg',
'images/iPad_1/de/page_2.jpg',
'images/iPad_1/de/page_3.jpg',
'images/iPad_1/de/page_4.jpg',
'images/iPad_1/de/page_5.jpg',
'images/iPad_1/de/page_6.jpg'
]
});

So it should work - I think!

On Mon, Apr 4, 2011 at 5:14 PM, avoision <feli...@gmail.com> wrote:
> Here's a question I have: you say that these images are in some kind
> of preloading list? Are the images packaged with your app, or are they
> being downloaded from some external location?
>
> I've not done any work on an iPad, but my thought would be to verify
> that you can actually view each of your images. Doing something a
> basic as placing them all on a blank page would be a start. That way
> you could isolate whether it was an issue with your preloader code, an
> issue with your images... or just something weird with deploying out
> to your device.

avoision

unread,
Apr 4, 2011, 11:14:12 AM4/4/11
to jQTouch

avoision

unread,
Apr 4, 2011, 3:49:39 PM4/4/11
to jQTouch
I could be wrong, but since you're including the images with the rest
of your files... you should just be able to reference them directly.
And would have no need to "preload" them.

Have you tried removing the display:none from the div, and verify that
you can see all your images clearly?

Sebastian Roming

unread,
Apr 4, 2011, 5:34:36 PM4/4/11
to jqt...@googlegroups.com
Can't verify that at the moment. I'm trying it tomorrow and will let you know.

Sebastian Roming

unread,
Apr 5, 2011, 4:38:44 AM4/5/11
to jqt...@googlegroups.com
No, that does not work :(
I removed the preloader and tried to display all images on the first
page - but every time I start random number of pictures is not shown.
:(

avoision

unread,
Apr 5, 2011, 10:45:24 AM4/5/11
to jQTouch
It's difficult for me to know what to recommend. Again, I haven't done
any development on an iPad... so I'm guessing pretty blindly here.

Based on your description, you're loading up all your images on one
page... and each time you view the page, random images do not appear.
Is this correct?

While I think it's unlikely that there's a problem with your images, I
would recommend creating a very basic HTML page that just displays
your images. Make sure you can see each image first, and that you
don't have any other competing code.

If your images are ok, I'm not sure what to recommend. Do you also
have some kind of onDeviceReady() check?

Sebastian Roming

unread,
Apr 6, 2011, 4:25:21 AM4/6/11
to jqt...@googlegroups.com, feli...@gmail.com
Tried that - put all images on a blank HTML page - without javascript
or css implementation.
In the meantime I updated the number of images to #18 and on the blank
page there are randomly 9 to 11 images displayed.
Reply all
Reply to author
Forward
0 new messages