try this new function in html_output.php
// New HTML image wrapper function modified for KISS Image Thumbnailer by FWR Media
function tep_image($src, $alt = '', $width = '', $height = '', $parameters = '') {
// If width and height are not numeric then we can't do anything with it
$imageg = @getimagesize($src);
// Check the input variables and decide what to do:
if($width > $imageg[0] && $height > $imageg[1]){
$image = '<img src="' . tep_output_string($src) . '" alt="' . tep_output_string($alt) . '"';
if (tep_not_null($alt)) {
$image .= ' title=" ' . tep_output_string($alt) . ' "';
}
$image .= ' '.$imageg[3];
if (tep_not_null($parameters)) $image .= ' ' . $parameters;
$image .= ' />';
return $image;
}else{
if ( !is_numeric ( $width ) || !is_numeric ( $height ) ) return tep_image_legacy( $src, $alt, $width, $height, $parameters );
require_once DIR_WS_MODULES . 'kiss_image_thumbnailer/classes/Image_Helper.php';
$attributes = array( 'alt' => $alt, 'width' => $width, 'height' => $height );
$image = new Image_Helper( array( 'src' => $src,
'attributes' => $attributes,
'parameters' => $parameters,
'default_missing_image' => DIR_WS_IMAGES . 'no_image_available_150_150.gif',
'isXhtml' => true,
'thumbs_dir_path' => DIR_WS_MODULES . 'kiss_image_thumbnailer/thumbs/',
'thumb_quality' => 75,
'thumb_background_rgb' => array( 'red' => 255,
'green' => 255,
'blue' => 255 ) ) );
if ( false === $image_assembled = $image->assemble() ) {
return tep_image_legacy( $src, $alt, $width, $height, $parameters );
}
return $image_assembled;
}
} // end function
it checks first the Image dimensions with the original - if both width and height are bigger - it will instead just link the original Image