Skip to content

Commit

Permalink
Chinese calendar js files don't load on Linux because they are not
Browse files Browse the repository at this point in the history
lowercase.
  • Loading branch information
infograf768 committed Feb 13, 2018
1 parent 8d7a917 commit facfbff
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions libraries/joomla/form/fields/calendar.php
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,10 @@ protected function getLayoutData()
{
$localesPath = 'system/fields/calendar-locales/' . strtolower($tag) . '.js';
}
elseif (is_file(JPATH_ROOT . '/media/system/js/fields/calendar-locales/' . $tag . '.js'))
{
$localesPath = 'system/fields/calendar-locales/' . $tag . '.js';
}
elseif (is_file(JPATH_ROOT . '/media/system/js/fields/calendar-locales/' . strtolower(substr($tag, 0, -3)) . '.js'))
{
$localesPath = 'system/fields/calendar-locales/' . strtolower(substr($tag, 0, -3)) . '.js';
Expand Down
4 changes: 4 additions & 0 deletions libraries/src/HTML/HTMLHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -1013,6 +1013,10 @@ public static function calendar($value, $name, $id, $format = '%Y-%m-%d', $attri
{
$localesPath = 'system/fields/calendar-locales/' . strtolower($tag) . '.js';
}
elseif (is_file(JPATH_ROOT . '/media/system/js/fields/calendar-locales/' . $tag . '.js'))
{
$localesPath = 'system/fields/calendar-locales/' . $tag . '.js';
}
elseif (is_file(JPATH_ROOT . '/media/system/js/fields/calendar-locales/' . strtolower(substr($tag, 0, -3)) . '.js'))
{
$localesPath = 'system/fields/calendar-locales/' . strtolower(substr($tag, 0, -3)) . '.js';
Expand Down

0 comments on commit facfbff

Please sign in to comment.