1
0
mirror of https://github.com/e107inc/e107.git synced 2025-07-31 11:50:30 +02:00

IN PROGRESS - task EONE-10: System thumbnails - thumb url options fixes and improvements

This commit is contained in:
secretr
2010-03-10 10:05:39 +00:00
parent 80168ed08b
commit e18b650bea

View File

@@ -1622,14 +1622,14 @@ class e_parse
if($raw) $url = $this->createConstants($url, 'mix');
$thurl = ($full ? SITEURL : e_HTTP).'thumb.php?src='.$url.'&';
if(vartrue($options['aw']))
if(vartrue($options['aw']) || vartrue($options['ah']))
{
$thurl .= 'aw='.intval($options['aw']).'&ah='.(vartrue($options['ah']) ? intval($options['ah']) : intval($options['aw']));
$thurl .= 'aw='.((integer) vartrue($options['aw'], 0)).'&ah='.((integer) vartrue($options['ah'], 0));
}
else
{
if(!vartrue($options['w'])) $options['w'] = 100;
$thurl .= 'aw='.intval($options['w']).'&ah='.(vartrue($options['h']) ? intval($options['h']) : intval($options['w']));
if(!vartrue($options['w']) && !vartrue($options['h'])) $options['w'] = 100;
$thurl .= 'w='.((integer) vartrue($options['w'], 0)).'&h='.((integer) vartrue($options['h'], 0));
}
return $thurl;