Saturday, 28 September 2013

Extjs, prevent images from being cached

 In order to prevent images from being cached just do one thing, append cache buster i.e cb=new Date() (or any other dynamic value could be replaced with new Date() object) to the the image source as query string , just as given below :

myImage.setSrc('../images/myImage/name.png'+'?cb='+new Date());

No comments:

Post a Comment