added resize capabilities for images