Shape 5

General Category => Suggestions => : uglyfashio December 10, 2011, 01:44:21 PM



: Use of CSS Sprites in the future please!
: uglyfashio December 10, 2011, 01:44:21 PM
Hey Shape5!  Help us out by using CSS Sprites in the future for templates.  You can use spriteme to achieve some of the work quite easily.  It speeds up page speed, and loading times add to conversions and google ranking.  Hurruh! 



: Re: Use of CSS Sprites in the future please!
: mikek December 11, 2011, 09:25:54 AM
Hello,

We actually use sprites pretty extensively now in our themes.


: Re: Use of CSS Sprites in the future please!
: uglyfashio December 21, 2011, 01:55:57 PM
Hey, thanks for the reply, yes you do, but you could go further still.

Your latest template for example.  You could probably put all of the images into one file (at least the ones that are not in a separate folder - just my first glance impression.).  The file size would remain small as the images are already tiny, the server requests would be reduced to 1.  Google would be happier.

http://spriteme.org/ - makes spriting quite easy.  Does the work for you a bit
http://css-tricks.com/css-sprites/ - explains why to use spritiing, shows you why it makes a difference (90/10 rule)
http://css-tricks.com/wp-content/csstricks-uploads/facebook-sprite.png an example of a Facebook sprite, a large high traffic website that utilises this technique.

I think this is probably the way forward in terms of reducing server requests, and if the evidence above is anything to go by it is worthwhile doing.  However, for your own purposes, it may make editing the templates slightly more difficult for some of your users.  I think you might create a few sprites, one for the image slider/fader etc., one for the main template etc.  That way they would be reusable across various templates.