At the moment there is no option in the xml-definition of the calendar to set another day than sunday as first-day of week. It would be nice if we can set the day inside the form-xml
Able to freely set the first day of week in the xml, like so for instance:
<field type="calendar" weekstart="monday" name="....
Labels |
Added:
?
|
Category | ⇒ | JavaScript |
Status | New | ⇒ | Discussion |
It is set in the language xml
<firstDay>0</firstDay>
is Sunday for en-GB.
<firstDay>1</firstDay>
is Monday for French fr-FR
We have no way in core to modify this by an override.
Hmm... ok, i guess we'll stick with the locale-version (our usage would have been to set the layout for a module/component independent of language or website ecc., since we have different administrators who speak different languages, and we want it to be consistent throughout without having to configure each language (often we have sites with 8-10 locales), but i guess the simplest solution would be to write to the locale.xml the same value for all languages).
Thanks anyways!
Status | Discussion | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2018-08-10 09:48:08 |
Closed_By | ⇒ | pixxelfactory |
In fact you can override...
code is in a Layout
/layouts/joomla/form/field/calendar.php
data-firstday="<?php echo JFactory::getLanguage()->getFirstDay(); ?>"
So I guess you can override that layout in your template
templates/nameoftemplate/html/layouts/joomla/form/field/calendar.php
I "think" it can be set in the language xml