Picture clause support for HTML5 forms picture-clause-support-for-html-forms

CAUTION
AEM 6.4 has reached the end of extended support and this documentation is no longer updated. For further details, see our technical support periods. Find the supported versions here.

HTML5 forms supports XFA Picture clause for display value and formatted value for date, text, and numeric symbols. Following Picture clause Expressions are supported:

  • category(locale){picture-clause} | category(locale){picture-clause} | category(locale)
  • category.subcategory{}
NOTE
At present, Mobiles Forms does not support Edit Picture clause. Also, DateTime and Time Picture clause symbols are not supported.

Supported Date Field Symbols supported-date-field-symbols

Supported expression for Date Picture clause:

  • date.long{}
  • date.short{}
  • date.medium{}
  • date.full{}
  • date.short{}
  • date
NOTE
The default pattern of picture clause is {MMM D, YYYY} pattern. If no pattern is applied, the default pattern is used.
Symbol
Interpretation
D
1- or 2-digit (1-31) day of the month
DD
Zero-padded two digit (01-31) day of the month.
M
1- or 2-digit (1-12) month of the year.
MM
Zero-padded two digit (01-12) month of the year.
MMM
Abbreviated month name of the current locale
MMMM
Full month name of the current locale
EEE
Abbreviated weekday name of the current locale
EEEE
Full weekday name of the current locale
YY
2-digit year, where 00 = 2000, 29 = 2029, 30 = 1930, and 99 = 1999
YYYY
4-digit year

Numeric Picture Clause numeric-picture-clause

HTML5 forms support Numeric Picture symbols. However, there is a difference in support between PDF Forms and HTML Forms.

In PDF Forms, a number is formatted irrespective of the number of symbols in the Picture clause has

In HTML Forms, a number is formatted only if the number has digits less than the number of symbols in the Picture clause.

Example: Consider a Picture clause: num{zzz,zzz,zz9}.

The number 10000 is formatted as 10,000 in both HTML and PDF Forms.

The number 1000000 is formatted as 1,000,000 in PDF forms. However, in HTML Forms the number remains unformatted as 1000000.

Supported expressions for Numeric Picture clause in HTML Forms are:

  • num.integer{}
  • num.decimal{}
  • num.currency{}
  • num.percent{}
  • num
Symbol
Interpretation
Input parsing
9
Output formatting: a single digit. Or for the zero digit if the input data is empty or a space in the corresponding position.
Single digit
Z
Output formatting: a single digit. Or for a space if the input data is empty, a space, or the zero digit in the corresponding position.
Single digit or space
z
Output formatting: a single digit. Or for nothing if the input data is empty, a space, or the zero digit in the corresponding position.
Single digit or nothing
E
Output formatting: the exponent part of a floating point number consisting of the exponential symbol (E). Followed by an optional plus or minus sign. Followed by the exponent value.
Same as for output formatting
CR or cr
Credit symbol (CR) if the number is negative. Else nothing.
S or s
Output formatting: a minus sign if the number is negative. Else space.
Minus sign if the number is negative. Plus sign if the number is positive
V
Decimal radix of the prevailing locale. Allowing the decimal radix to be implied when input parsing.
v
Decimal radix of the prevailing locale. Allowing the decimal radix to be implied when input parsing and output formatting.
.
Decimal radix of the prevailing locale.
, (U+FF0C)
Grouping separator of the prevailing locale
$ (U+FF04)
Currency symbol of the prevailing locale.
% (U+FF05)
Percent symbol of the prevailing locale.
( (U+FF08)
Left parenthesis if the number is negative. Else space.
) (U+FF09)
Right parenthesis if the number is negative. Else space.
t
Tab Character

Text Picture Clause text-picture-clause

HTML5 forms support the following Text Picture clause expressions:

  • text
Symbol
Interpretation
A
Single alphabetic character.
X
Single character.
O
Single alphanumeric character.
0 (zero)
Single alphanumeric character.
9
Single digit.
recommendation-more-help
a6ebf046-2b8b-4543-bd46-42a0d77792da