able to resize the uploaded image when its size is larger than assigned.