summaryrefslogtreecommitdiffstats
path: root/doc/antora/modules/unlang/pages/xlat/character.adoc
blob: 84a148cf1b024b69eb186b7aab637f78ada975bb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
= Single Letter Expansions

The following are single letter expansions.  These expansions do not
use the typical `%{...}` format.  Instead, they are short-cuts for
simple, common cases.

== Miscellaneous

`%%`::

Returns `%`.


== Current Time

`%c`::

The current Unix epoch time in seconds. This is an unsigned decimal number.
It should be used with time-based calculations.

`%C`::

The microsecond component of the current epoch time. This is an unsigned
decimal number. It should be used with time-based calculations.


== Request Time

`%l`::

The Unix timestamp of when the request was received. This is an unsigned
decimal number. It should be used with time-based calculations.

`%Y`::

Four-digit year when the request was received.

`%m`::

Numeric month when the request was received.

`%d`::

Numeric day of the month when the request was received.

`%H`::

Hour of the day when the request was received.

`%G`::

Minute component of the time when the request was received.

`%e`::

Second component of the time when the request was received.

`%M`::

Microsecond component of the time when the request was received.

`%D`::

Request date in the format `YYYYMMDD`.

`%S`::

Request timestamp in SQL format, `YYYY-mmm-ddd HH:MM:SS`.

`%t`::

Request timestamp in _ctime_ format, `Www Mmm dd HH:MM:SS YYYY`.

`%T`::

Request timestamp in ISO format, `YYYY-mm-ddTHH:MM:SS.000`.


// Copyright (C) 2020 Network RADIUS SAS.  Licenced under CC-by-NC 4.0.
// Development of this documentation was sponsored by Network RADIUS SAS.