Featured Links

French German Italian Portuguese Russian Spanish

Login

TY2U.com Designs Logo

Free Joomla Templates

Date and Time

Date and Time Module for Joomla!

Displays the current time and date any way you want it.

Please report any bugs, feature requests, or support requests in the forums.

Click to Download

Be sure to configure the module parameters to your liking.
 

Tip: You can use HTML too! For example:   or   entered in a text box or as a separator will become a space.

If you see strange characters, such as a black diamond with a question mark in it � in the Separators section, don't be alarmed. It is how a space gets saved. Joomla! won't allow you to use a regular space properly by itself so you have to use an HTML entity for it. Unfortunately when it gets loaded back into the module it becomes this strange character: � so it gets converted to a space on output to the front-end of the site.

 

Documentation

 

Information:
Daylight Saving Time / Summer Time: http://en.wikipedia.org/wiki/Daylight_saving_time

 

Parameters

If you want to use nothing in a parameter where there is something by default you could set it to a blank a tag or span tag for example.

 

System Output

System output parameters.

Module Class Suffix
A suffix to be applied to the css class of the module (table.moduletable), this allows individual module styling.

Caching
Select whether to cache the content of this module

Possible Values:

Use global - will use the cache settings found in the Global Configuration.

No Caching - will not cache output

Cache Time
The time before the module is recached

Compress
You can choose to compress the Javascript output.

 

Generation Method

Choose where the date and time will come from.

Generation Method
Use PHP or Javascript method to generate date and time - Javascript will generate the date and time using Javascript and will update in realtime.

When using Javascript it will show the date and time to the visitor as it is set on their computer, not the time from the web server, because this uses client-side Javascript.

PHP will generate the date and time using PHP.

When using PHP to generate the time it will show the time of the web server where PHP is installed.

Note that the Time zone offset will affect both Javascript and PHP methods, however when using the PHP method to generate the date and time this is only an offset of hours from the server and does not relate to your time zone.

Possible Values:

Javascript
PHP

 

Enclosure

HTML or text output for to be displayed immediately before and after the module output.

Pre-text
This is the Text or HTML that is displayed before the module.

Post-text
This is the Text or HTML that is displayed after the module.

 

Display

Some display settings.

Display order of date and time
Which to display first, the date or the time?

Possible Values:

Display Date First
Display Time First

Alignment
The alignment of the date and time.

Possible Values:

None
Left
Center
Right

Show on separate lines or on the same line?
Choose to display the date and time on two separate lines or on the same line.

Possible Values:

Separate lines
Same line

 

Date

Settings related to date formatting.

Display Date?
Do you wish to display the date?

Possible Values:

Yes
No

Date prefix
Text displayed before the date.

i.e. Date: 02/24/2007

Leave blank to display nothing.

Date suffix
Text displayed after the date.

i.e. 02/24/2007 Date

Leave blank to display nothing.

Display order of date
Order of the parts of the date.

w=day of the week

(Monday, Tuesday, etc.)

d=day of the month

(21st, 22nd, etc.)

m=month

(March, April, etc.)

y=year

(2007, 2008, etc.)

Simply leave a part out if you don't wish to display it.

Example:

Entering [w,d,m,y] will display [Monday, 4th June 2007] but entering only [d,m,y] will display [4th June 2007].

Hint: Don't use the brackets [ ] just the letters and commas.

Use ISO 8601 date format
Disregard most options and output date in ISO 8601 format. (requires PHP5 if using PHP method) For more information see module description above for URL.

Possible Values:

No
Yes

 

Time

Settings related to time.

Display Time?
Do you wish to display the time?

Possible Values:

Yes
No

Time prefix
Text displayed before the time.

i.e. Time: 4:49pm

Leave blank to display nothing.

Time suffix
Text displayed after the time.

i.e. 05:00 hours

Leave blank to display nothing.

Time zone offset
Time zone offset in hours. Only enter a number of hours here.  For example -5 or +3 works fine.When using PHP method this is only an offset of hours from the server and does not relate to your time zone.

Automatic switching of DST / Summer Time
Automatically compensate for Daylight Saving Time / Summer Time. For more information see module description above for URL.

Javascript uses the times below to determine when to adjust the time.

PHP automatically detects this from the server and does not use those dates. You will usually want to shut this off when using PHP method if your server adjusts its time automatically.

Possible Values:

Off
On

DST / Summer Time Begins
Date and time Daylight Saving Time / Summer Time begins. You can enter any year but the format must match this exactly: [March 14, 1999 2:59:59] For more information see module description above for URL.

PHP method automatically detects Daylight Savings Time / Summer Time.

DST / Summer Time Ends
Date and time Daylight Saving Time / Summer Time ends. You can enter any year but the format must match this exactly: [November 7, 1999 2:59:59] For more information see module description above for URL.

PHP method automatically detects Daylight Savings Time / Summer Time.

Use 24 hour time?
Choose whether to use 24 hour time or not. i.e. 04:30:11 or 19:31:13

Possible Values:

Yes
No

Display hours?
Choose whether to display hours or not.

Possible Values:

Yes
No

Display minutes?
Choose whether to display minutes or not.

Possible Values:

Yes
No

Display seconds?
Choose whether to display seconds or not.

Possible Values:

Yes
No

Show am / pm?
Choose whether to display am/pm or not.

Possible Values:

Yes
No

Text to use for A.M.
Displays this text for A.M.

Text to use for P.M.
Displays this text for P.M.

 

Separators

Allows you to modify the separators.

Separator to display before the {value}

Displays this text or symbol before the {value}

Separator to display after the {value}
Displays this text or symbol after the {value}

 

Day of the week output

Allows you to change the week output.

Text to use for {Weekday}
Displays this text for {Weekday}

 

Month output

Allows you to change the month output.

Display the month as
Text = use parameters below.

Number = 03, 04, 05, etc.

Possible Values:

Text
Number

Text to use for {Month}
Displays this text for {Month}

 

Day of the month output

Change the output of days of the month.

Display days of the month as
Text = user parameters below.

Number = 1, 2, 3, 4, etc.

Possible Values:

Text
Number

{#day} day of the month
Displays this text for {#day} of the month

 


 

Some parts of the code are derived from sites on the internet.

These sites include:
http://www.joomla.org/
http://php.net/
http://www.yaldex.com/
http://www.cs.tut.fi/~jkorpela/iso8601.html
http://www.quirksmode.org/

 


 

Changelog - Moved to changelog.php in 2.2

Thank you to everyone who helps along the way =)

Add comment


Security code
Refresh

 

(C) Copyright 2008 - 2010 TY2U.com Designs, All Rights Reserved
Free Joomla Templates