mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-05 02:44:27 +02:00
fixed bug in traversal of $smarty->plugins_dir-array in
smarty_core_assemble_plugin_filepath(). the first matching plugin in the path should be used, not the last one.
This commit is contained in:
2
NEWS
2
NEWS
@@ -1,3 +1,5 @@
|
|||||||
|
- fixed bug in traversal of $smarty->plugins_dir-array. now the
|
||||||
|
first matching plugin is taken (messju)
|
||||||
- moved {strip} back into the compiler (messju)
|
- moved {strip} back into the compiler (messju)
|
||||||
- fixed config_load: handling of section-attribute and use of
|
- fixed config_load: handling of section-attribute and use of
|
||||||
multiple config-files in one template (atu, messju)
|
multiple config-files in one template (atu, messju)
|
||||||
|
@@ -28,11 +28,13 @@ function smarty_core_assemble_plugin_filepath($params, &$smarty)
|
|||||||
// relative path, see if it is in the SMARTY_DIR
|
// relative path, see if it is in the SMARTY_DIR
|
||||||
if (@is_readable(SMARTY_DIR . $_plugin_filepath)) {
|
if (@is_readable(SMARTY_DIR . $_plugin_filepath)) {
|
||||||
$_return = SMARTY_DIR . $_plugin_filepath;
|
$_return = SMARTY_DIR . $_plugin_filepath;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// try relative to cwd (or absolute)
|
// try relative to cwd (or absolute)
|
||||||
if (@is_readable($_plugin_filepath)) {
|
if (@is_readable($_plugin_filepath)) {
|
||||||
$_return = $_plugin_filepath;
|
$_return = $_plugin_filepath;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user