Index: branches/RC/core/units/images/image_tag_processor.php =================================================================== diff -u -N -r10098 -r10832 --- branches/RC/core/units/images/image_tag_processor.php (.../image_tag_processor.php) (revision 10098) +++ branches/RC/core/units/images/image_tag_processor.php (.../image_tag_processor.php) (revision 10832) @@ -193,16 +193,14 @@ $max_width = $this->getImageDimension('Width', $params); $max_height = $this->getImageDimension('Height', $params); + $format = array_key_exists('format', $params) ? $params['format'] : false; - // user watermarks from format param - if (!$max_width) { - $max_width = $params['format']; - if ($max_width) { - $max_height = null; - } + if (!$max_width && $format) { + // user watermarks from format param + $max_width = $format; } - if ($max_width > 0 || $max_height > 0 || $params['format']) { + if ($max_width > 0 || $max_height > 0 || $format) { $image_helper =& $this->Application->recallObject('ImageHelper'); /* @var $image_helper ImageHelper */ @@ -235,7 +233,18 @@ } $default_image = $this->SelectParam($params, 'default_image,DefaultImage'); - return ($ret && $ret != $base_url) ? $ret : ($default_image ? $base_url.THEMES_PATH.'/'.$default_image : false); + + if ($ret && $ret != $base_url) { + // 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 false; } function getFullPath($path) @@ -299,6 +308,7 @@ $params['alt'] = htmlspecialchars($object->GetField('AltName')); // really used ? $params['name'] = $this->SelectParam($params, 'block,render_as'); $params['align'] = array_key_exists('align', $params) ? $params['align'] : 'left'; + $params['no_editing'] = 1; if (!$object->isLoaded() && !$this->SelectParam($params, 'default_image,DefaultImage')) { return false;