Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Image ontop of Image?
#2
So you want your background images to be Links? Have you tried Css?

Start with just a link exactly as you would make it for any other purpose, and make sure to give the link an id so that we can use that to apply our styles:

Code:
<a href="http://xavisys.com" title="Site" id="image">Link</a>

So, how can we make a background image a clickable link? It turns out it can be done with a clever CSS trick. Let’s get started by adding the background image and make the link the same size as the image (so you can see the whole image). Since an anchor tag isn’t a block level element, we need to force it to display as “block” so that we can specify the size:


Code:
#xavisys-logo {
    background-image:url(/wp-content/uploads/2009/11/email_logo.gif);
    display:block;
    height:58px;
    width:200px;
}

^Set that as your CSS

hope it helps.
Reply


Messages In This Thread
Image ontop of Image? - by rlogin - 07-11-2011, 11:23 AM
RE: Image ontop of Image? - by Billy Mays - 07-11-2011, 02:25 PM
RE: Image ontop of Image? - by Kyle FYI™ - 07-11-2011, 02:49 PM
RE: Image ontop of Image? - by Billy Mays - 07-11-2011, 02:56 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  how to locate a certain image/path mrlips 4 1,451 03-16-2011, 05:25 PM
Last Post: AceInfinity
  Postbit image problems Detective RooTz 5 1,597 01-19-2010, 06:50 PM
Last Post: Detective RooTz
  Flash or JS image rotator Tim 4 1,076 01-07-2010, 08:13 PM
Last Post: Tim
  Image problem with IE8 cortexaz 18 3,822 12-23-2009, 01:04 PM
Last Post: cortexaz
  Image map help, please. Elektrisk 1 723 12-09-2009, 10:30 AM
Last Post: Gaijin

Forum Jump:


Users browsing this thread: 2 Guest(s)