docs.roxen.comView this page in a printer friendly mode
DocsRoxen2.2Web Site Creator ManualInformation Tags
Copyright © 2004, Roxen Internet Software
Suggestions, comments & compliments
manuals@roxen.com
 DEMO  DOCS  PIKE
 COMMUNITY  DOWNLOAD
www.roxen.com

   

<accessed>
<configurl>
<countdown>
<date>
<help>
<modified>
<number>
<roxen>
<user>

<date/>

Provided by module: Tags: RXML 2 tags

Inserts the time and date. Does not require attributes.


<date/>
18:37, July the 12th, 2002

Attributes

unix-time="number of seconds"

Display this time instead of the current. This attribute uses the specified Unix 'time_t' time as the starting time (which is 01:00, January the 1st, 1970), instead of the current time. This is mostly useful when the <date> tag is used from a Pike-script or Roxen module.


<date unix-time='120'/>
01:02, January the 1st, 1970

timezone="{local, GMT}" (local)

Display the time from another timezone.


years="number"

Add this number of years to the result.


<date date='' years='2'/>
July the 12th in the year of 2004

months="number"

Add this number of months to the result.


<date date='' months='2'/>
September the 12th in the year of 2002

weeks="number"

Add this number of weeks to the result.


<date date='' weeks='2'/>
July the 26th in the year of 2002

days="number"

Add this number of days to the result.


hours="number"

Add this number of hours to the result.


<date time='' hours='2' type='iso'/>
20:37:52

beats="number"

Add this number of beats to the result.


<date time='' beats='10' type='iso'/>
18:52:16

minutes="number"

Add this number of minutes to the result.


seconds="number"

Add this number of seconds to the result.


adjust="number"

Add this number of seconds to the result.


brief

Show in brief format.


<date brief=''/>
today, 18:37

time

Show only time.


<date time=''/>
18:37

date

Show only date.


<date date=''/>
July the 12th in the year of 2002

type="{string, ordered, iso, discordian, stardate, number, unix}"

Defines in which format the date should be displayed in. Discordian and stardate only make a difference when not using part. Note that type='stardate' has a separate companion attribute, prec, which sets the precision.

type=discordian


<date date='' type='discordian'/>
Pungenday, the 46th day of Confusion

type=iso


<date date='' type='iso'/>
2002-07-12

type=number


<date date='' type='number'/>
July the 12th in the year of 2002

type=ordered


<date date='' type='ordered'/>
July the 12th in the year of 2002

type=stardate


<date date='' type='stardate'/>
37447.5

type=string


<date date='' type='string'/>
July the 12th in the year of 2002

type=unix


<date date='' type='unix'/>
1026491872

part="{year, month, day, wday, date, mday, hour, minute, second, yday, beat, week, seconds}"

Defines which part of the date should be displayed. Day and wday is the same. Date and mday is the same. Yday is the day number of the year. Seconds is unix time type. Only the types string, number and ordered applies when the part attribute is used.

PartMeaning

year

Display the year.


<date part='year' type='number'/>
2002

month

Display the month.


<date part='month' type='ordered'/>
7th

day

Display the weekday, starting with Sunday.


<date part='day' type='ordered'/>
6th

wday

Display the weekday. Same as 'day'.


<date part='wday' type='string'/>
Friday

date

Display the day of this month.


<date part='date' type='ordered'/>
12th

mday

Display the number of days since the last full month.


<date part='mday' type='number'/>
12

hour

Display the numbers of hours since midnight.


<date part='hour' type='ordered'/>
18th

minute

Display the numbers of minutes since the last full hour.


<date part='minute' type='number'/>
37

second

Display the numbers of seconds since the last full minute.


<date part='second' type='string'/>
fiftytwo

yday

Display the number of days since the first of January.


<date part='yday' type='ordered'/>
192nd

beat

Display the number of beats since midnight Central European Time(CET). There is a total of 1000 beats per day. The beats system was designed by Swatch as a means for a universal time, without time zones and day/night changes.


<date part='beat' type='number'/>
@734

week

Display the number of the current week.


<date part='week' type='number'/>
28

seconds

Display the total number of seconds this year.


<date part='seconds' type='number'/>
1026491872

strftime="string"

If this attribute is given to date, it will format the result according to the argument string.

FormatMeaning

%%

Percent character

%a

Abbreviated weekday name, e.g. "Mon"

%A

Weekday name

%b

Abbreviated month name, e.g. "Jan"

%B

Month name

%c

Date and time, e.g. "%a %b %d %H:%M:%S %Y"

%C

Century number, zero padded to two charachters.

%d

Day of month (1-31), zero padded to two characters.

%D

Date as "%m/%d/%y"

%e

Day of month (1-31), space padded to two characters.

%H

Hour (24 hour clock, 0-23), zero padded to two characters.

%h

See %b

%I

Hour (12 hour clock, 1-12), zero padded to two charcters.

%j

Day numer of year (1-366), zero padded to three characters.

%k

Hour (24 hour clock, 0-23), space padded to two characters.

%l

Hour (12 hour clock, 1-12), space padded to two characters.

%m

Month number (1-12), zero padded to two characters.

%M

Minute (0-59), zero padded to two characters.

%n

Newline

%p

"a.m." or "p.m."

%r

Time in 12 hour clock format with %p

%R

Time as "%H:%M"

%S

Seconds (0-61), zero padded to two characters.

%t

Tab

%T

Time as "%H:%M:%S"

%u

Weekday as a decimal number (1-7), 1 is Sunday.

%U

Week number of year as a decimal number (0-53), with sunday as the first day of week 1, zero padded to two characters.

%V

ISO week number of the year as a decimal number (1-53), zero padded to two characters.

%w

Weekday as a decimal number (0-6), 0 is Sunday.

%W

Week number of year as a decimal number (0-53), with sunday as the first day of week 1, zero padded to two characters.

%x

Date as "%a %b %d %Y"

%X

See %T

%y

Year (0-99), zero padded to two characters.

%Y

Year (0-9999), zero padded to four characters.


<date strftime="%B %e %Y, %A %T"/>
July 12 2002, Friday 18:37:52

lang="langcode"

Defines in what language a string will be presented in. Used together with type=string and the part attribute to get written dates in the specified language.


<date part='day' type='string' lang='de'/>
Freitag

case="{upper, lower, capitalize}"

Changes the case of the output to upper, lower or capitalize.


<date date='' lang='&client.language;' case='upper'/>
JULY THE 12TH IN THE YEAR OF 2002

prec="number"

The number of decimals in the stardate.