Creating thumbnails dynamically using ASP

This page shows 4 photographs in JPG format. The views shown below have been dynamically resized using csImageFile. Clicking on each image will link to the full size JPEG image.

This technique of displaying smaller versions of images gives the developer a great deal of flexibility, especially when working with a large picture collection. It is not necessary to produce an individual thumbnail for each image in advance.

This page is simple and contains no important scripting. Each <img> tag points to another script which calls csImageFile, resizes the JPG and streams it using BinaryWrite. The name of each image is passed in the URL, as shown below.


<img src="showthumb.asp?JpegName=scarborough1">

Click Here for the listing and description of "showthumb.asp", the script that produces each image.

For interest the photographs are all taken in Scarborough, North Yorkshire. They are our own photographs so you can copy them if you like.


This site uses cookies for functionality, traffic analysis and for targeted advertising. Click the Accept button to accept our Cookie Policy. The Cookie Policy page offers configuration for a reduced set of cookies for this site.