Hi I tried to set lazy loading of images in shopping website. Everything worked fine but when it comes for loading image that in "data-src" I find it difficult to set width and height for image inside data-src. Kindly help me with how to set height and width.
<img data-src="image/apple_600x450.jpg" src="img/loader.gif" style="width:100px; height:100px;" >
the above style works only for image inside src but it has no effect of data-src. Kindly help me to set
max-width
max-height
width
height
for image inside data-src.
Thanks in advance.
Bootstrap uses
data-srcinstead ofsrc, it's because of the pluginholder.js.data-srcis only used for the javascript library that generates the example images of a certain size, andsrcis the normal attribute for specifying the location of an image. See the holder.js documentation here.