I was just wondering how I can make thumbnails of images stored in hdd and use them in an html page, also I need the thumbnails to be able to enlarge (to their original size
Lookup the PECL extension Imagick. It's usually installable with standard package-managers.
http://se2.php.net/Imagick
You can either dynamically create the thumbnails and serve them using .php files (slow) or make a thumbnail-copy that you store on the server (prefered)