- This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
Viewing 3 posts - 1 through 3 (of 3 total)
- The forum ‘Other’ is closed to new topics and replies.
The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Hi. I used css image sprite for my website. In the home page I am using images for logo and etc. In this case logo is in the anchor tag. sprite image is using for 5 images in the home page. When the page is loading , sprite image is called two times. Because I used sprite image as a background for anchor tag of the logo. Without anchor tag , sprite image is called only one time. I need put anchor tag for logo. How to solve the sprite issue. when I load the home page it takes too long for loading for the sprite image two times calling. If it is called only once, then the loading time is reduced.
.logo-home a
{
background:url(/content/images/sprite.jpg) no-repeat scroll center 0px;
display:block;
height:95px;
}
img.home-students-image {
width: 227px;
height: 93px;
background: url(/Content/images/sprite.jpg) no-repeat scroll -211px -365px;
}
Hi Kvr,
The first time the images is used it will be downloaded from the internet, any further times you use the image it will be loaded form the cache, so won’t be downloaded again.
/content/images/sprite.jpg
/Content/images/sprite.jpg
Typo? Try giving both images the same URL.