1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-05 14:17:49 +02:00

Fix for broken thumbnails while using {e_xxxx}

This commit is contained in:
CaMer0n
2011-08-19 23:39:44 +00:00
parent 7e49828958
commit d633f5c239

View File

@@ -1755,6 +1755,11 @@ class e_parse
public function thumbUrl($url, $options = array(), $raw = false, $full = false)
{
if(substr($url,0,3)=="{e_") // Fix for broken links that use {e_MEDIA} etc.
{
$url = $this->replaceConstants($url);
}
if(!is_array($options))
{
parse_str($options, $options);
@@ -1763,6 +1768,7 @@ class e_parse
if($raw) $url = $this->createConstants($url, 'mix');
$thurl = ($full ? SITEURL : e_HTTP).'thumb.php?src='.$url.'&';
if(vartrue($options['aw']) || vartrue($options['ah']))
{
$thurl .= 'aw='.((integer) vartrue($options['aw'], 0)).'&ah='.((integer) vartrue($options['ah'], 0));