Never been to TextSnippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world (or not, you can keep them private!)

« Newer Snippets
Older Snippets »
1 total  XML / RSS feed 

Cross-browser solution for adding hover border to linked images

// The class is assigned to the href.

.borderit img {
        border: 1px dashed #776e09;
        padding: 2px;
}
.borderit:hover img {
        border: 1px solid #fff71c;
        padding: 2px;
}
.borderit:hover {
        color: red; /* irrelevant definition to overcome IE bug */
}
« Newer Snippets
Older Snippets »
1 total  XML / RSS feed