/ Published in: CSS

[via rtcrm]
Image/Text replacement for clickable image. This is useful for logo images.
Image/Text replacement for clickable image. This is useful for logo images.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
<h1> <a href="/">RTC<em>RM</em></a> </h1> h1 { font properties here } h1 a { // This can be any inline element: span, strong, em, etc. display: block; // This forces the <a> element to be as wide as the containing <h1> width: XXXpx; height: XXXpx; background: url('../img/logo.gif') no-repeat 0 0; overflow: hidden; text-indent: -9999px; } /* Example from header on 2008 RTCRM public site */
Comments
