Hi,
I'm currently trying to use the x:inputDate tag and unless I set the type to "both" (or something other than type and date.) I find that the parse() method of the UserData innerclass will always throw a ParseException. Having looked at the HtmlDateRenderer source code I have decided that this occurs because the Renderer never sets the values of the Day Month Year -- if type is time -- or Minute Hour Second -- if the type is date. This results in them remaining null and hence failing when the parse occurs.
I think the correct place to fix this is in HtmlDateRenderer.encodeEnd(), and I attach a patch which should fix it. The only issue I can see at the moment, is if someone was to dynamically change the type of the input it would lose the old information.
Thanks, andy
PS Do know your mail archives for January are broken?
-- Andrew Thornton [EMAIL PROTECTED]
diff -r1.14 HtmlDateRenderer.java
268c268,272
< }
---
> } else {
> userData.setDay("01");
> userData.setMonth("01");
> userData.setYear("1970");
> }
274c278,282
< }
---
> } else {
> userData.setHours("00");
> userData.setMinutes("00");
> userData.setSeconds("00");
> }
