mirror of
https://github.com/smarty-php/smarty.git
synced 2025-11-03 13:51:36 +01:00
fix capitalize modifier to not rely on buggy ucwords() func
This commit is contained in:
@@ -130,8 +130,7 @@ function smarty_function_html_select_date($params, &$smarty)
|
||||
}
|
||||
// If $time is not in format yyyy-mm-dd
|
||||
if (!preg_match('/^\d{0,4}-\d{0,2}-\d{0,2}$/', $time)) {
|
||||
// then $time is empty or unix timestamp or mysql timestamp
|
||||
// using smarty_make_timestamp to get an unix timestamp and
|
||||
// use smarty_make_timestamp to get an unix timestamp and
|
||||
// strftime to make yyyy-mm-dd
|
||||
$time = strftime('%Y-%m-%d', smarty_make_timestamp($time));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user