Bin Chen
Bin Chen

Reputation: 63299

website acceleration, loading other web pages resource?

I am wondering if such technology exists. In PageA, when the loading is completed, PageA began to load resouces in PageB, which is very likely to be accessed after some time(predict).

If the loading is succeeded, then most of the resource in PageB will be already in cache. The resource including swf, js, images, etc.

Thanks.

Upvotes: 1

Views: 165

Answers (3)

Gumbo
Gumbo

Reputation: 655129

Yes, some web sites use techniques of prefetching to enhance the loading time of certain web pages. Just think of an photo gallery, slide show, or a series of web pages in general where it is very likely that the next photo/slide/page is viewed as well.

In that case you could prefetch the resources of the next page on the current page to lower the remaining loading time of the next page.

Common techniques are

But besides the benefits of lower loading times of subsequent pages you should also be aware that using prefetching can also prefetch resources that are not used (i.e. the assumption that the user does visit the next page is wrong).

Upvotes: 1

Habax
Habax

Reputation: 1332

I always preload images when I'm pretty sure about the next page. You can use this code at the end of your page:

<script type="text/javascript">
preload=new Image();
preload.src="future_image.jpg";
</script>

Upvotes: 1

Nick Craver
Nick Craver

Reputation: 630349

Yes, it exists, some browsers do this, it's called prefetching. However it's often not done by default in normal browsing (though DNS prefetching often is)...it's mainly used for offline viewing support.

Upvotes: 1

Related Questions