image resizing functio added