English 中文(简体)
提供光箱图像链接
原标题:Provide link to lightbox image
  • 时间:2012-05-24 07:49:33
  •  标签:
  • php
  • jquery

我用一个光箱(jquery. lightbox-0.5.js)来显示我的画廊页面。我的图像显示代码是

<ul>
  <div class="gallery" id="gallery1">
    <li> <a style="display: inline;" href="sample.jpg" target="_blank"> <img src="sample_thumb.jpg" alt=""  /> </a> </li>
  </div>
</ul>

它的工作顺利。

但现在我想提供 Lightbox 图像的链接。 即, 在点击 Lightbox 内的图像时, 我想将用户重定向到其他页面 。

但我不知道该如何实现这个目标?有人知道吗?事先谢谢。

最佳回答

在您 html 中设置“ a” 标签的标题, 并将其设置为您想要的链接。 当图像被单击时, 在放大后的图像底部, 您可以看到一个链接, 您可以单击和浏览 。

<ul>
  <div class="gallery" id="gallery1">
    <li> <a style="display: inline;" href="sample.jpg" target="_blank" title="&lt;a href= http://google.com &gt;My Link. Click Me&lt;/a&gt;"> <img src="sample_thumb.jpg" alt=""  /> </a> </li>
  </div>
</ul>
问题回答

暂无回答




相关问题
Brute-force/DoS prevention in PHP [closed]

I am trying to write a script to prevent brute-force login attempts in a website I m building. The logic goes something like this: User sends login information. Check if username and password is ...

please can anyone check this while loop and if condition

<?php $con=mysql_connect("localhost","mts","mts"); if(!con) { die( unable to connect . mysql_error()); } mysql_select_db("mts",$con); /* date_default_timezone_set ("Asia/Calcutta"); $date = ...

定值美元

如何确认来自正确来源的数字。

Generating a drop down list of timezones with PHP

Most sites need some way to show the dates on the site in the users preferred timezone. Below are two lists that I found and then one method using the built in PHP DateTime class in PHP 5. I need ...

Text as watermarking in PHP

I want to create text as a watermark for an image. the water mark should have the following properties front: Impact color: white opacity: 31% Font style: regular, bold Bevel and Emboss size: 30 ...

How does php cast boolean variables?

How does php cast boolean variables? I was trying to save a boolean value to an array: $result["Users"]["is_login"] = true; but when I use debug the is_login value is blank. and when I do ...

热门标签