Thanks Lee for the good bug report.
I have implemented a fix for the format tag that allows
it to ignore any whitespace in the body of the tag.
After I review the other datetime taglib feature requests,
I'll update the taglib on the jakarta site.
Thanks,
Glenn
Lee Ball wrote:
>
> Also I have one small bugette to point out with <dt:format> (apologies if
> you've updated it recently).
>
> If you use <dt:format pattern="MM/dd/yyyy
> hh:mm"><dt:currenttime/></dt:format> like in the docs then
> fine but if you try
>
> <dt:format pattern="MM/dd/yyyy hh:mm">
> <dt:currenttime/>
> </dt:format> an exception is thrown because something is coughing out in the
> parse.
>
> Cheers
> Lee
>
> -----Original Message-----
> From: Mark Femal [mailto:[EMAIL PROTECTED]]
> Sent: 23 April 2001 17:15
> To: [EMAIL PROTECTED]
> Subject: datetime TAGlib -> FormatTag.java
>
> Hi Glenn (et. al.)
>
> Started to use the Jakarta datetime lib and wanted to suggest a few
> improvements (nothing earth-shattering here, just some small suggestions):
>
> 1. Addition of a "date" and "defaultText" attribute:
> date = used for formatting (overrides tag body)
> defaultText = if NumberFormatException when parsing body or date ==
> null this is the text used for defaults
>
> The above allows you to significantly cut down on the amount of code for
> formatting (i.e. you can do something like this:
> <td width="50%">Last Unsuccessful Login:</td>
> <td width="50%">
> <dt:format pattern="M-d-yyyy 'at' hh:mm:ss zzz"
> defaultText=" "
> date="<%= bean.getLastBadLoginDate() %>" />
> </td>
>
> rather than checking to see if lastBadLoginDate == null explicitly and
> also having a default format -- especially useful for table and formatting
> based on data obtained via data sources.
>
> 2. Adjustments to tld: (ADD)
>
> <attribute>
> <name>date</name>
> <required>false</required>
> <rtexprvalue>true</rtexprvalue>
> </attribute>
> <attribute>
> <name>defaultText</name>
> <required>false</required>
> <rtexprvalue>false</rtexprvalue>
> </attribute>
>
> excellent work BTW on the taglib! I'll have more suggestions maybe
> later...
--
----------------------------------------------------------------------
Glenn Nielsen [EMAIL PROTECTED] | /* Spelin donut madder |
MOREnet System Programming | * if iz ina coment. |
Missouri Research and Education Network | */ |
----------------------------------------------------------------------