mirror of
https://github.com/e107inc/e107.git
synced 2025-08-03 21:27:25 +02:00
IN PROGRESS - task EONE-10: System thumbnails - thumb url options fixes and improvements
This commit is contained in:
@@ -1622,14 +1622,14 @@ class e_parse
|
|||||||
if($raw) $url = $this->createConstants($url, 'mix');
|
if($raw) $url = $this->createConstants($url, 'mix');
|
||||||
|
|
||||||
$thurl = ($full ? SITEURL : e_HTTP).'thumb.php?src='.$url.'&';
|
$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
|
else
|
||||||
{
|
{
|
||||||
if(!vartrue($options['w'])) $options['w'] = 100;
|
if(!vartrue($options['w']) && !vartrue($options['h'])) $options['w'] = 100;
|
||||||
$thurl .= 'aw='.intval($options['w']).'&ah='.(vartrue($options['h']) ? intval($options['h']) : intval($options['w']));
|
$thurl .= 'w='.((integer) vartrue($options['w'], 0)).'&h='.((integer) vartrue($options['h'], 0));
|
||||||
}
|
}
|
||||||
|
|
||||||
return $thurl;
|
return $thurl;
|
||||||
|
Reference in New Issue
Block a user