The module worked great with "Site's time zone", but it generated several PHP errors for "Date's time zone" that also resulted in a validation error that emptied the value from the form after it was redrawn.
* Warning: timezone_open(): Unknown or bad timezone (A) in date_combo_validate() (line 508 of .../modules/misc/date/date/date_elements.inc).
* Warning: date_timezone_set() expects parameter 2 to be DateTimeZone, boolean given in date_combo_validate() (line 508 of .../modules/misc/date/date/date_elements.inc).
* Warning: timezone_open(): Unknown or bad timezone (A) in date_combo_validate() (line 509 of .../modules/misc/date/date/date_elements.inc).
* Warning: date_timezone_set() expects parameter 2 to be DateTimeZone, boolean given in date_combo_validate() (line 509 of .../modules/misc/date/date/date_elements.inc).
* There are errors in <field name>:
o The From date is invalid.
o The To date is invalid.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 1108022.date_single_day.render-remaining-form.patch | 847 bytes | joachim |
| #1 | timezone.patch | 590 bytes | stackpr |
Comments
Comment #1
stackpr commentedAttached is a patch that addresses this issue the same way the rrule field is handled currently.
Comment #2
joachim commentedThanks for reporting this, and also making a patch!
The patch works, though I think it might be better to play safe and just render everything that's left in the form -- so we avoid surprises like this in future.
Could you test this patch please?
Comment #3
stackpr commentedWorks great.
Comment #4
joachim commentedThanks!
Issue #1108022 by witti, joachim: Fixed errors on datefields with a timezone.