Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    ksp
    ksp is offline
    New to the CF scene
    Join Date
    Oct 2006
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    CSS & clickable image

    Hi,
    I would like to know how do I make this code a clickable image.
    the image is GIF file and I want to be able to click on it and link me to another website. thanks

    <style type="text/css">
    table table table td {vertical-align:top ! important;}
    span.blacktext12 {
    visibility:visible !important;
    background-color:transparent;
    background-image:url("http://hqwedding.com/MS_layoutpix/cutebanner.gif");
    background-repeat:no-repeat;
    background-position:center center;
    font-size:0px; letter-spacing:-0.5px;
    width:435px; height:75px; display:block !important; }
    span.blacktext12 img {display:none;}
    </style>

  • #2
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    You could put the onclick event in that td

    <td onclick="location='http://www.whereever.com'">
    The silent one.

    The most dangerous thing in the world is an idea.
    The most dangerous person in the world is the one with an idea.

  • #3
    Regular Coder
    Join Date
    Mar 2005
    Location
    D0u$h!t3 k4?
    Posts
    512
    Thanks
    2
    Thanked 5 Times in 5 Posts
    Or you could do something like this:
    Code:
    <td>
        <span class="blacktext12"><a href="http://www.whereever.com">&nbsp;</a></span>
    </td>
    Cheap trick with the &nbsp;, but it works.
    PHP Code:
    $hello file_get_contents('hello.txt'); echo $hello
    hello

  • #4
    ksp
    ksp is offline
    New to the CF scene
    Join Date
    Oct 2006
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    More Help

    thanks guys for the quick reply and helps.

    can you copy and paste my code and then add your new code into mine.
    I am not so sure where to place the new code.
    thanks

  • #5
    Regular Coder
    Join Date
    Mar 2005
    Location
    D0u$h!t3 k4?
    Posts
    512
    Thanks
    2
    Thanked 5 Times in 5 Posts
    You can't do it with CSS. The code we both gave you was based on the CSS you gave us. We guessed what the code was that you had. Post your X/HTML too and we can help more.
    PHP Code:
    $hello file_get_contents('hello.txt'); echo $hello
    hello


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •