Page is a not externally linkable
- Code, Content, and Presentation
-- JavaScript and AJAX
---- Preload using js


tedster - 3:10 am on Jun 29, 2001 (gmt 0)


The 1x1 image pre-load has the benefit of being pure HTML rather than JavaScript. But the method has the downside of creating a dot on the page.

If you trust using JavaScript, you can get an invisible preload by including this at the very bottom your HTML code (so it doesn't slow down the loading for the visible page:

<script type="text/javascript" language="JavaScript">
<!--

big=new Image(width,height)
big.src="big.gif"

//-->
</script>

All this code does is cache the image for later use, the way you would do with a roll-over image, and nothing is visible until you want it to be.


Thread source:: http://www.webmasterworld.com/javascript/641.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com