23 Apr
2002
23 Apr
'02
8:13 p.m.
I have an HTML form with a text field into which I wish to place the current date, properly formatted, as a default value. In the form, I have the following DTML: < input type="text" name="start_date" value=<dtml-var "(_.DateTime().strftime('%b. %d, %Y'))">> This code is copied verbatim from another page on one of my other Zope sites where it produces the day's date just beautifully. In this case, it only displays the first formatted element (day name in this case, but I've proven that it will display the first item whatever it is) in the form's text field. If I use the exact same code in a textarea multi-line field on an HTML form, it displays the entire formatted date correctly. Known bug? Workarounds? Personal insanity?