resize(array( 'width_max' => 300, 'height_max' => 100, )); $image->output_jpg(); ?>