sauravbhattacharya001 / Javascript-Image-Zoom

Zoom images in an HTML file to user-defined levels

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Javascript-Image-Zoom

Zoom images in an HTML file to user-defined levels

Files contained

  • pic.png - test image that is zoomed
  • image-zoom.js - Javascript file that scales any provided image file to twice (pic.png provided as a sample)
  • index.html - HTML file which renders the original and scaled image

How to use with original sample image

  1. Put the three aforementioned files in a single directory
  2. Open index.html in a Javascript supported browser to view scaled version of the sample pic.png

How to use with any image

  1. Put image-zoom.js and index.html in a single directory
  2. In the same directory, put the image file to be scaled
  3. Rename the image file to "pic." ( being the extension of the image file)
  4. Open index.html in a Javascript supported browser to view scaled version of the custom pic.png

About

Zoom images in an HTML file to user-defined levels