mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-04 18:34:27 +02:00
match first character of file-attribute against "/" instead of
DIRECTORY_SEPARATOR since it is a url-path and not a file-path.
This commit is contained in:
@@ -113,8 +113,8 @@ function smarty_function_html_image($params, &$smarty)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$_params = array('resource_type' => 'file', 'resource_name' => $_image_path);
|
$_params = array('resource_type' => 'file', 'resource_name' => $_image_path);
|
||||||
require_once(SMARTY_DIR . 'core' . DIRECTORY_SEPARATOR . 'core.is_secure.php');
|
require_once(SMARTY_DIR . 'core' . DIRECTORY_SEPARATOR . 'core.is_secure.php');
|
||||||
if(!$smarty->security && !smarty_core_is_secure($_params, $smarty)) {
|
if(!$smarty->security && !smarty_core_is_secure($_params, $smarty)) {
|
||||||
$smarty->trigger_error("html_image: (secure) '$_image_path' not in secure directory", E_USER_NOTICE);
|
$smarty->trigger_error("html_image: (secure) '$_image_path' not in secure directory", E_USER_NOTICE);
|
||||||
return;
|
return;
|
||||||
|
Reference in New Issue
Block a user