APEX-AT-WORK no image

Preload images in APEX

Von Tobias Arnhold 12.11.2010
Sometimes images doesn't appear immediately (for example loading icons called before onSubmit processes). Especially new users who doesn't have these images inside there browser cache could be happy to see them. :)

The workaround is quite easy. Just create a Dynamic Action like below:

Create Dynamic Action: preload_images
Event: Page Load
Action: Execute JavaScript Code
Code:

var a_imgList = new Array();
// Your images
a_imgList[0] = "/i/company/loading1.gif";
a_imgList[1] = "/i/company/loading2.gif";
a_imgList[2] = "/i/company/button1.gif";
a_imgList[3] = "/i/company/button2.gif";

var a_images = new Array()

for (i = 0; i < a_imgList.length; i++) {
a_images[i] = new Image();
a_images[i].src = a_imgList[i];
}

Create Dynamic Action

That's it! You probably would add this event on your login page 101.

Post Tags: