If I try to use the FormAPI date element from a custom module or profile.module, I get:
* notice: Array to string conversion in .\includes\form.inc on line 882.
* notice: Undefined index: #children in .\includes\form.inc on line 1254.
and the element is not expanded to the 3 select controls as expected.
With FAPI3, the #process property no longer supports parameters (see: http://drupal.org/node/144132#custom-params)
The 'date' entry in system_elements() was not updated for this change ('checkboxes' and 'radios' were)
Patch attached to fix this
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | system.module.date__0.patch | 1020 bytes | Rok Žlender |
| form_date_element_fix.patch | 1.04 KB | asimmonds |
Comments
Comment #1
Rok Žlender commentedIssue http://drupal.org/node/159494 has been marked as a duplicate of this one.
I tested the patch and now the date field works. Simpletest tests of profile module which uses date field are now green.
Comment #2
Rok Žlender commentedPatch from assimonds still applies but with
Hunk #1 succeeded at 115 with fuzz 1 (offset 5 lines).
Rerolled and it now applies cleanly.
Comment #3
dries commentedCommitted. Thanks.
Comment #4
(not verified) commented