==== new modifiers for the ajaxSearch Phx parser
to include images in your templates, uses the possible following phx modifiers:
imgwidth : image width - e.g: <img src="[+as.imageArticle+]" width="[+as.imageArticle:imgwidth+]" />
provide the image width
imgheigth : image heigth - e.g: <img src="[+as.imageArticle+]" heigth="[+as.imageArticle:imgheigth+]" />
provide the image height
imgattr : image attributs - e.g: <img src="[+as.imageArticle+]" [+as.imageArticle:imgattr+] />
provide the image attributes as height="xxx" width="yyy"
imgmaxwidth=`length` : image max width - e.g: <img src="[+as.articleImage+]" width="[+as.articleImage:imgmaxwidth=`60`+]" />
limit the width of the image to a maximum. Under this limit, keep the true width
imgmaxheight=`length` : image max height - e.g: <img src="[+as.articleImage+]" height="[+as.articleImage:imgmaxheight=`100`+]" />
limit the height of the image to a maximum. Under this limit, keep the true height
These modifiers are particularly usefull with the ajax mode to help html to determine the height of the AjaxSearch pop-up window
case "imgwidth": list($width, $height, $type, $attr) = getimagesize($output); $output = $width; break;
case "imgheight": list($width, $height, $type, $attr) = getimagesize($output); $output = $height; break;
case "imgattr": list($width, $height, $type, $attr) = getimagesize($output); $output = $attr; break;
case "imgmaxwidth":
list($width, $height, $type, $attr) = getimagesize($output);
$output = ($width < intval($modifier_value[$i])) ? $width : intval($modifier_value[$i]);
break;
case "imgmaxheight":
list($width, $height, $type, $attr) = getimagesize($output);
$output = ($height < intval($modifier_value[$i])) ? $height : intval($modifier_value[$i]);
break;
[+phx:if=`[+paginaAfbeelding+]`:ne=``:then=` <div class="samenvatting_afbeelding" style="width: [+paginaAfbeelding:imgmaxwidth=`175`+]px;"> <a href="[~[+id+]~]"><img src="[+paginaAfbeelding+]" border="0" width="[+paginaAfbeelding:imgmaxwidth=`175`+]" title="lees verder..."></a> </div> `+]
case "imgmaxwidth":
if($output != āā){list($width, $height, $type, $attr) = getimagesize($output);
$output = ($width < intval($modifier_value[$i])) ? $width : intval($modifier_value[$i]);}
break;