C H A P T E R  9

image

Supporting Other Languages

In this chapter, you'll learn how to develop an application that can appear in two or more different languages to suit users in different countries.

Displaying the Current Date and Time

Suppose that you have an application that displays the current date and time, as shown in Figure 9-1.

images

Figure 9-1. Displaying the current date and time

To do that, create a new dynamic web project as usual named MultiLang. Then create a showdate.xhtml file, as shown in Listing 9-1.

Listing 9-1. showdate.xhtml

<!DOCTYPE ...

Get Beginning JSF™ 2 APIs and JBoss® Seam now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.