#626 Time and Date Configuration

Parent Category:
DPCalendar
Category:
Configuration
Last Updated:
Allon Moritz, Wednesday, 30 October 2019 15:22 (Wednesday, 30 October 2019)
Created:
Wednesday, 06 June 2012 10:32 (Wednesday, 06 June 2012)
Hits:
18210

Introduction

The DPCalendar Joomla event manager offers options within a module or menu link configuration to adapt the date and time format of the displayed events. This means the user can customize the date appearance to suit their needs and target audience.

The PHP date commands allow you to render the date in almost any combination you wish. To achieve that, the date and time configuration must fit the PHP date syntax.

Time and date options

Date formats

The following list are examples of date and time formats:

  • d.m.Y H:i transforms into 12.04.2011 15:38
  • h a transforms into 8 pm
  • c transforms into 2012-02-12T15:19:21+00:00
  • D, j M Y G:i:s transforms into Sat, 19 Jun 2010 15:09:35

Every date command is executed within the translator. Means you can use ordinary strings as date or time format and then do a language override for them. This offers the possibility to use different formats per language.

Timezone setup

Joomla has different timezone settings, the global Joomla timezone and the user timezone. As default the user timezone is inherited from the Joomla timezone, means when the Joomla timezone changes then the user timezone changes too. Timezones are important for a Calendar and Event manager extension like DPCalendar is, as it defines how dates are displayed and how day light summer time (DST) is handled. Initially every Joomla site comes with the UTC timezone pre configured. The timezone in Joomla can be changed on the following link System -> Global Configuration -> Server tab.

Additionally you can enable the timezone switcher in the DPCalendar options, which allows to change the actual timezone by the visitor himself.

Time and date timezone

Change time display

DPCalendar renders the start and end time according to the event set up. This means when the event is an all day event, then only the dates are displayed, otherwise the times as well.

Hide end time per event

There is an additional setting when you edit an event where you can hide the end time. This means that DPCalendar will not show anywhere the end time of the event. You still have to set it for export reasons, but within DPCalendar it will not be displayed.

Override event output

Sometimes site admins do want to change the order of the dates or display only part of it, etc. To achieve this you need to create a layout override (not a template override).

Copy the file /components/com_dpcalendar/layouts/event/datestring.php to /templates/{{your template}}/html/layouts/com_dpcalendar/event/datestring.php and adapt the it to your needs.

Event time display

Comments (0)

Cookies make it easier for us to provide you with our services. With the usage of our services you permit us to use cookies.