Displaying dates is often not very difficult. A simple text output with some date pattern applied to it will be sufficient most of the time. However, letting users enter a date is a whole different story. Today, users more-or-less expect some nice calendar pop up or something similar to input a date. To cater for this need, Tomahawk offers us two different date input components— <t:inputCalendar>
and <t:inputDate>
. The former displays a little calendar, either inline or as a pop up. The latter displays separate fields for day, month, and year, where the month field is displayed as a drop-down list. Both can optionally let the user enter a time, too. We will only take a look at the <t:inputCalendar>
component in this book. The <t:inputDate>
component has some issues with Facelets and also lacks the possibility to change the order of the day, month, and year fields. This makes this component rather useless.
The <t:inputCalendar>...