Reloading the same image

I have a page in the cms part of my site (javascript is turned on and can make me choose a browser), this is a calendar with a lot of images:

<img src='1.gif' />
<img src='1.gif' />
<img src='1.gif' />
<img src='1.gif' />

<img src='2.gif' />
<img src='2.gif' />
<img src='2.gif' />
<img src='2.gif' />

the same image can be used more than 250 times, while about 1000-1500 images will be displayed on the page.

Is the browser smart enough to realize that it is still the same image, or is there some kind of javascript / jQuery that I can use to improve performance?

+3
source share
2 answers

If they have the same real path, the browser will cache them if you do not have aggressive anti-cache headers, such as expiration headers in the past.

+2
source

, , . . @Alex .

, / . .

DOM:

<img src='1.gif' />
<img src='1.gif' />

Chrome, Firefox IE9, , . , , 304 .

, - , , .

+3

All Articles