在Prettyphoto.js或Fancybox中...如何在标题中添加链接 [英] In Prettyphoto.js or Fancybox... How to add a link within the caption

查看:87
本文介绍了在Prettyphoto.js或Fancybox中...如何在标题中添加链接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

帮助!我正在为一个作家团队开发网站.

Help! I'm working on a website for a team of writers.

他们想通过阴影框效果展示他们所从事的特定工作的示例(作品集).

They want to show examples of specific jobs they've worked on (portfolio) by using the shadowbox effect.

打开(叠加)图片实际上是例如.doc的屏幕截图,将带有标题以粗略地解释它.事实是,他们希望在标题内提供一个链接,以便用户可以将文件(.doc,.pdf)下载到他们的桌面或链接到他们曾经工作过的另一个站点.

Once opened (in overlay) the picture which is actually a screenshot of a .doc for instance, would have a caption to explain it roughly. The thing is, they want a link inside the caption so the user can download the files (.doc, .pdf) to their desktop or link to another site that they haved worked on.

我设法用Fancybox做到了,但是当链接悬停时,链接中包含的链接的方式显示了不想要的文本(浏览器黄色的工具提示).

I've managed to do it with Fancybox but the way the link is included in the it shows undesirable text when hovered (the browser yellow tooltip).

这是代码:

<a class="group" rel="portfolio"
 href="../../images/pf_nat/cfcBig.png" title="Rédaction de plus de 300 articles. <a href='http://www.groupecfc.com/fr-Ca/' target='_blank'>Visiter le site</a>"><img src="../../images/pf_nat/tn_nat_cfcBig.gif" alt="" width="40" height="40"/></a>

在这种情况下,它是指向某个网站的链接.

in this case it's a link to some site.

推荐答案

如果像大多数灯箱"插件一样,我认为您需要使用字符实体来进行此操作,例如:

If it's like most 'lightbox' plugins, I believe you need to do this use character entities for example:

<a href="test.html">hello</a>

将成为

&lt;a href=&quot;text.html&quot;&gt;hello&lt;/a&gt;

将其放在您的标题标签中,它将链接.

Put this in your title tag and it will link.

http://en.wikipedia.org/wiki/List_of_XML_and_HTML_character_entity_references中获取HTML字符实体的完整列表

这篇关于在Prettyphoto.js或Fancybox中...如何在标题中添加链接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆