The plug-in name is elevatezoom.
To achieve this effect, you need to prepare two images, one small one and the other large for displaying when the mouse passes. Then, we only need to add the data-zoom-image attribute for the img label, and its value is the address of the big image. Finally, select the image in javascript and call elevateZoom.
The following is an example (this example is available in the code downloaded from github ):
Copy codeThe Code is as follows:
<! DOCTYPE html>
<Html>
<Head>
<Meta charset = 'utf-8'/>
<Title> jQuery elevateZoom Demo </title>
<Script src = 'jquery-1.8.3.min.js '> </script>
<Script src = 'jquery. elevateZoom-2.3.0.min.js '> </script>
</Head>
<Body>
<H1> Basic Zoom Example
<Br/>
See more examples online <a href = "http://www.elevateweb.co.uk/image-zoom/examples"> http://www.elevateweb.co.uk/image-zoom/examples </a>
<Script>
$ ('# Zoom_01'). elevateZoom ();
</Script>
</Body>
</Html>
The implementation result is as follows:
I have not studied the specific code, but I know how to use it. I would like to share it here.