April 25, 201016 yr Hey, I've no doubt that this is a well-worn theme, but I've been going around in circles with this for an hour or so and don't seem to be getting anywhere with it, so I'm hoping someone here can help? What I need is some javascript that will preload my webpage, and once everything is 'preloaded' then automatically forward the user (i.e. the preloader is in 'index.html', once everything is loaded you go to 'index2.html'. What I don't want are loading bars, flash content, 'pre-loading bar provided by...' tags etc. Basically, I want to keep it simple. Can anyone point me in the right direction? Any help would be much appreciated. Adam.
May 6, 201016 yr Pre-loading assumes caching. which is a client side thing. I do not fully understand your desire. If you wish to preload "index2.html", while the user is looking on index.html. You can do this by adding this to index.html (subject to client support) <head> <link rel="prefetch" href="index2.html"> </head> If you wish index.html to be a holding page, and to automatically forward the user to index2.html once items you wish to preload are cached. you could do. <style> body { display: hidden } </style> <body onload="window.location.href='index2.html'"> <!-- cache images --> <img src="url"/> <img src="url"/> <img src="url"/> ... </body> I do not recommend this tho. MikeyB Hey, I've no doubt that this is a well-worn theme, but I've been going around in circles with this for an hour or so and don't seem to be getting anywhere with it, so I'm hoping someone here can help? What I need is some javascript that will preload my webpage, and once everything is 'preloaded' then automatically forward the user (i.e. the preloader is in 'index.html', once everything is loaded you go to 'index2.html'. What I don't want are loading bars, flash content, 'pre-loading bar provided by...' tags etc. Basically, I want to keep it simple. Can anyone point me in the right direction? Any help would be much appreciated. Adam.
Create an account or sign in to comment