Index: branches/RC/core/units/images/image_tag_processor.php =================================================================== diff -u -r10832 -r11404 --- branches/RC/core/units/images/image_tag_processor.php (.../image_tag_processor.php) (revision 10832) +++ branches/RC/core/units/images/image_tag_processor.php (.../image_tag_processor.php) (revision 11404) @@ -205,7 +205,7 @@ /* @var $image_helper ImageHelper */ $src_image = FULL_PATH.$object->GetDBField('ThumbPath'); - return $image_helper->ResizeImage($src_image, $max_width, $max_height); + return file_exists($src_image)? $image_helper->ResizeImage($src_image, $max_width, $max_height) : $this->_getDefaultImage($params); } } @@ -232,19 +232,26 @@ } } - $default_image = $this->SelectParam($params, 'default_image,DefaultImage'); - - if ($ret && $ret != $base_url) { + if ($ret && $ret != $base_url && file_exists($ret)) { // image name and it's not just folder name return $ret; } - elseif ($default_image) { - // show default image, use different base urls for admin and front-end - $sub_folder = $this->Application->IsAdmin() ? rtrim(IMAGES_PATH, '/') : THEMES_PATH; - return $base_url . $sub_folder . '/' . $default_image; + + // return Default Image or false if NOT specified + return $this->_getDefaultImage($params); + } + + function _getDefaultImage($params) + { + if (!$default_image = $this->SelectParam($params, 'default_image,DefaultImage')) { + return false; } - return false; + // show default image, use different base urls for admin and front-end + $base_url = rtrim($this->Application->BaseURL(), '/'); + $sub_folder = $this->Application->IsAdmin() ? rtrim(IMAGES_PATH, '/') : THEMES_PATH; + + return $base_url . $sub_folder . '/' . $default_image; } function getFullPath($path)