From b6f63ff778ae221a55fc2c291a90752b2360df6e Mon Sep 17 00:00:00 2001 From: Robert Lyon Date: Wed, 10 Jul 2019 16:12:23 +1200 Subject: [PATCH] Bug 1835988: Needing to include datepicker *.js files correctly When the site is a subdirectory behatnotneeded Change-Id: I53a562f9fb5c7f52132cbabd00bb6bb3969a35f3 Signed-off-by: Robert Lyon --- htdocs/lib/pieforms/pieform/elements/calendar.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/lib/pieforms/pieform/elements/calendar.php b/htdocs/lib/pieforms/pieform/elements/calendar.php index 79e84dd60b..7f8908d496 100644 --- a/htdocs/lib/pieforms/pieform/elements/calendar.php +++ b/htdocs/lib/pieforms/pieform/elements/calendar.php @@ -271,8 +271,8 @@ function pieform_element_calendar_get_headdata($element) { $libjs = $element['jsroot'] . 'js/jquery-ui.min.js'; $libcss = $element['jsroot'] . 'css/smoothness/jquery-ui.min.css'; - $bootstrapdatetimejs = '/js/bootstrap-datetimepicker/tempusdominus-bootstrap-4.js'; - $momentjs = '/js/momentjs/moment-with-locales.min.js'; + $bootstrapdatetimejs = get_config('wwwroot') . 'js/bootstrap-datetimepicker/tempusdominus-bootstrap-4.js'; + $momentjs = get_config('wwwroot') . 'js/momentjs/moment-with-locales.min.js'; $prev = get_string('datepicker_prevText'); $next = get_string('datepicker_nextText'); $result = array( -- GitLab