Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

As you can see, this is a very powerful mechanism and allows you to easily display numbers and dates using any formatting rules that Java allows.

Info
titlevalue0 interface deprecated

The examples above pass in the values as:

Code Block

<webwork:text name="'text.message" value0="userName"/>

These values should now (>2.1.7?) be passed as params:

Code Block

<webwork:text name="'text.message'"> 
    <webwork:param value="userName'"/>
</webwork:text>
Tip
titleSome message format examples

Here are some examples of formatting in the properties file:

Code Block

format.date = {0,date,MM/dd/yy}
format.time = {0,date,MM/dd/yy ha}
format.percent = {0,number,##0.00'%'}
format.money = {0,number,$##0.00}