views:

29

answers:

1

In the first picture of my website (the two persons), shows an URL address when you click on it. I used the "title" thing. Is there a simple way of doing the same but placing a link instead?

code:

<div class="pusher">
        <h3><?php echo l('showcase1_h3'); ?></h3>
        <p><?php echo l('showcase1_p'); ?></p>
        <div class="pic">
             <a id="showcase1" title="studyatbest.com" href="images/showcase1.png"><img src="images/showcase1t.png"/></a>
        </div>
</div>

http://alexchen.co.nr/

+1  A: 

Hi, yes there is, you need to use the titleFormat: Option.

    function titleLink(title, currentArray, currentIndex, currentOpts) {
   return '<div id="title-link"><span><a href="http://' + title + '">' + (title && title.length ? '<b>' + title + '</b>' : '' ) + '</a></span></div>';
 }

   $("a#fancyLink").fancybox({
    'titlePosition' : 'inside',
    'titleFormat' : titleLink
   });

Then in your markup:

<a id="fancyLink" href="./img.jpg" title="www.google.com"><img alt="Img link" src="./img.jpg" /></a>

I hope this meets your needs.

DRL