Drupal 8 is capable of supporting sites in multiple languages. The details of the translation mechanism are discussed later. The regional and language settings allow you to set some defaults for the target market of your site.
Go to Configuration | Regional and language | Regional settings (admin/config/regional/settings
).
From here you can set the Default country and First day of the week. These will have been set based on your choices during the install process, but you can change them now if they are incorrect.
The default time zone for the site will also have been set based on the country you selected during the install process. You can change this now, but also you can decide whether you want to allow visitors to your site to specify their own time zone.
If you allow visitors to determine their own time zone, time-sensitive data will be presented to that user in their own localized time. This would affect, for example, the posting times of articles or the time of an event.
Go to Configuration | Regional and Language | Date and time formats (admin/config/regional/date-time
).
Here you can set the date formats for your site.
By default, there will be a set of date formats which may not be appropriate for your local users:
Format Name |
Presented as |
---|---|
Long |
Saturday, December 19, 2015 - 10:23 |
Medium |
Sat, 12/19/2015 - 10:23 |
Short |
12/19/2015 - 10:23 |
For example, in the UK, dates are presented as dd/mm/yyyy
as opposed to mm/dd/yyyy
, so let's change this now.
Click on Edit on the medium date format and edit it to the UK standard.
Entering a valid date format string here will ensure that all dates presented in short form will display in your new format. You can see the effect of this immediately in the preview.
Similarly, edit the short format to UK style too.
The current value uses standard PHP abbreviations for dates that can be found in full at http://php.net/manual/function.date.php.
Now when you go back to the article list views we created earlier, the new date formats will be applied.