It appears you have not yet registered with DEVPPL. To register please click here... (it's fast, easy and free!)

Forum

Log In Sponsors
Board index Programming CSS Forum

Multiple requests to same image sprite

Multiple requests to same image sprite

Postby Mvbshfala on Wed Aug 03, 2011 4:22 am

Hey guys, this one is a stumper. So I have an image sprite for my star rating, which has the three different stars in it. Since it uses a different star for different actions, it uses a different CSS selector (three different CSS selectors) to grab the correct star. Well, this turns a ~4K image into a 13K request, which blew my site above the 2 second load times. Is there any way css can load the image just once, then just use the same image (already loaded into the users browser) to select the specific star?
Mvbshfala
 
Posts: 33
Joined: Sat Jul 02, 2011 1:05 am

Re: Multiple requests to same image sprite

Postby rajmv on Wed Aug 03, 2011 2:52 pm

You must be doing something very strange..

I use sprites all the time, and i get only 1 request for an image that is smaller than the individual images combined.

Post your code to let us help you.
rajmv
100+ Club
 
Posts: 103
Joined: Thu Jul 14, 2011 7:22 am


Who is online

Users browsing this forum: No registered users and 0 guests