Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
On google chrome the input type="date" will display as a date input control, but the control's date format is MM/dd/yyyy, and can't change.
So when I click "Save and publish" to create a new node, drupal will display a error for the "Authored on" date field.
Attach file is the screen capture.
My Chrome version is 31.0.1650.63.
Comment | File | Size | Author |
---|---|---|---|
#5 | drupal-core-datetime-2159345-5.patch | 1.57 KB | tarekdj |
#2 | node-2159345-2.jpg | 158.85 KB | sidharthap |
Create_article.png | 126.12 KB | harryzhxu |
Comments
Comment #1
harryzhxu CreditAttribution: harryzhxu commentedComment #2
sidharthapI test it on Version 31.0.1650.63 Ubuntu 12.04 and could not replicate the same.
Comment #3
tarekdj CreditAttribution: tarekdj commentedTested on Version 31.0.1650.63 win 7. It works without problem.
Update:
If you want to reproduce this, remove all values from time filed (only time filed). But I think it makes sense because if you want to use the time of form submission you have to empty the date field too.
Comment #4
swentel CreditAttribution: swentel commentedComment #5
tarekdj CreditAttribution: tarekdj commentedSo here is a patch. Basically it empty time input when date input is empty and vise versa.
Comment #7
tarekdj CreditAttribution: tarekdj commentedWell! seems not to be the best solution for that.
Comment #8
swentel CreditAttribution: swentel commentedYeah, the javascript is not going to fire in the testbot. This might be a duplicate of #2031183: Improve test coverage for node authored on widget, but I'll leave it open for now.
Comment #9
vijaycs85Ok, the date/time element is HTML 5 element and has different display in different browser. Don't see any issue with datetime module for this. The author field issue(#2031183: Improve test coverage for node authored on widget) seems different one. So closing this for now.
Comment #10
vijaycs85