resize image and show slider photo