如何在单击其缩略图时显示全分辨率图像 [英] How to display full resolution image at click of its thumbnail

查看:180
本文介绍了如何在单击其缩略图时显示全分辨率图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经制作了html + javascript代码。根据哪个页面加载时图像大小减少到50,50并点击它,大小增加到500,500,但我用图像的一个副本完成了它/>

但我希望点击照片的thumnail并显示thumnail的完整分辨率。


I have made the html+javascript code.According to which when the page loaded the image size gets reduced to 50,50 and onclicking on it ,size increases to 500,500,but i done it with the one copy of image

But i want the click at thumnail of photos and display the full resolution of thumnail.


展开 | 选择 | Wrap | 行号

推荐答案

您应该创建一个通用函数,该函数可以获取图像名称,ID或对图像本身的引用。然后替换document.TheImage。使用 document.images [imageName]。来引用正确的图像。
You should make a generic function which either takes the image name, ID or a reference to the image itself. Then replace "document.TheImage." with document.images[imageName]. to reference the correct image.




有一个查看此链接


谢谢和问候

Ramanan Kalirajan
Hi,
Have a look over this link

Thanks and Regards
Ramanan Kalirajan


我有一个html兼javascript代码。有2个图像,一个是thumnail,另一个是全分辨率的当有人点击thumnail时,完整的resl。将显示和点击完整resl。 thumnail会显示。它很顺利,但问题是,当点击thumnail时,它会替换到其他看起来非常奇怪的图像的距离。

我希望在点击thumnail后它能够显示它完整的资源。没有影响同一页面上的其他图像。请看看http://highslide.com/"。我想要那样的东西。


这是我的HTML暨javascript代码



i have a html cum javascript code.There are 2 images one is thumnail and other is full resolution of the same.When somebody click the thumnail ,the full resl. would show and when click of full resl. the thumnail would show.It is going well but problem is that ,when click of thumnail ,it replaces a distance to other images that is looking very strange.
I want that after clicking on thumnail it shoult show the full res. without effecting the other images on the same page.Please take the look at "http://highslide.com/".I want something like that.

This is my html cum javascript code




展开 | 选择 | Wrap < span class =codeDivider> | 行号


这篇关于如何在单击其缩略图时显示全分辨率图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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