spudly.shuoink.com

the best way to predict the future is to implement it

Entries Comments


Steal These Buttons! - CSS Sprite Style

13 February, 2008 (20:58) | CSS

We’ve all seen these buttons floating around the internet. Every other website you see uses them, proclaiming their standard compliance. They’re called “steal these buttons” and there are a number of websites where you can download them.

Here’s my set, in the form of a CSS Sprite. In case you don’t know what that is, a css sprite is one image that gets split into many images using cascading style sheets. This way you load one big image instead of 50 small images, thus dramatically reducing the number of requests made by the web browser, which makes the page load much faster.

Here it is / Here they are:

And here’s how you use it:

First, include the stylesheet.

   <link href="stb.css" rel="stylesheet" type="text/css" />

Second, add the image to the page. You do so by adding a link. Examples for each is contained in the test.html file included in the zip file.

   <a href="http://jigsaw.w3.org/css-validator/" class="stb stbCss"></a>

Download Now

« PHP Template Engine

 PHP Error Log Parser »

Write a comment