Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我生成一个 HTML 页面,其中包含指向目录中图像的链接。
首先,我想加载/显示所有图像,然后使用 jQuery 隐藏它们。.hide()当用户单击图像时,我将显示该图像,但我希望您能提供更好的方法。
.hide()
仅当用户单击链接时才可以加载/显示图像?你能给我推荐一个插件或 PHP 脚本吗?
您可以使用Ibox并执行以下操作:
<a href="http://site.com/img.jpg" rel="ibox">Image 1</a>
当有人单击此链接时,图像将显示在一个小的悬停窗口中。
lightbox,ThickBox 可以解决问题。
在灯箱技术下查看这个: 灯箱技术