diff --git a/e107_core/shortcodes/batch/news_shortcodes.php b/e107_core/shortcodes/batch/news_shortcodes.php index 6d92063c7..b52d68b0e 100644 --- a/e107_core/shortcodes/batch/news_shortcodes.php +++ b/e107_core/shortcodes/batch/news_shortcodes.php @@ -733,7 +733,7 @@ class news_shortcodes extends e_shortcode $this->imageItem = varset($media[$parm['item']]); // Set the current Image for other image shortcodes. - if(vartrue($parm['placeholder'])) + if(!empty($parm['placeholder'])) { return $this->sc_newsimage('placeholder'); } @@ -853,10 +853,10 @@ class news_shortcodes extends e_shortcode } else { - + if(empty($srcPath)) { - if(varset($parm['type']) == 'placeholder' || vartrue($parm['placeholder'])) + if(varset($parm['type']) == 'placeholder' || !empty($parm['placeholder'])) { $src = $tp->thumbUrl(); // placeholder; $dimensions = $tp->thumbDimensions(); @@ -899,8 +899,9 @@ class news_shortcodes extends e_shortcode $imgParms = array( 'class'=>$class, - 'alt'=>basename($src), - 'style'=>$style + 'alt'=>basename($srcPath), + 'style'=>$style, + 'placeholder'=>varset($parm['placeholder']) ); diff --git a/e107_handlers/e_parse_class.php b/e107_handlers/e_parse_class.php index 41d66eb6d..a713303f7 100644 --- a/e107_handlers/e_parse_class.php +++ b/e107_handlers/e_parse_class.php @@ -3962,29 +3962,34 @@ class e_parser public function toImage($file, $parm=array()) { - if(empty($file)) - { - return null; - } - if(strpos($file,'e_AVATAR')!==false) { return "
{NEWS_SUMMARY}
+{NEWS_SUMMARY: limit=60}