image replacement


/ Published in: CSS
Save to your folder(s)

glider levin method


Copy this code and paste it in your HTML
  1. <h1><a href="./" title="Return Home"><span></span>Home</a></h1>
  2.  
  3. #header h1 a{
  4. display:block; /* Required */
  5. width:250px; /* Width of image in question */
  6. height:70px; /* Height of image in question */
  7. position:relative; /* Required */
  8. }
  9. #header h1 a span{
  10. position:absolute; /* Required */
  11. width:100%; /* Stretch full width of parent */
  12. height:100%; /* Stretch full height of parent */
  13. background:url(images/logo.gif) top left no-repeat; /* Image */
  14. cursor:pointer; /* Required for links to appear like links in IE */
  15. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.