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.
After updating to rc2 this message appeared when I tried to save a node after adding a new date:
The value input for field Datum Start date value #2 is invalid: The month is missing
The cause in my case is that the month string generated ("Feb") has a capitalized first letter. When I change it to lowercase (months are written in lowercase in Swedish) it works and translates into a proper formatted date string when I save the node.
Comment | File | Size | Author |
---|---|---|---|
#31 | date.png | 9.3 KB | Karthick Krthck |
#8 | 1432702-1.patch | 679 bytes | drzraf |
Comments
Comment #1
KarenS CreditAttribution: KarenS commentedNot enough information to know how to reproduce this. I can't tell what kind of date field you created, what options you gave it or anything else that would make it possible to see what you're talking about. I suspect you have some inconsistency in the way you have the field set up and the way you want it to behave.
Comment #2
ordermind CreditAttribution: ordermind commentedThe field type is Date (ISO format) and the widget is Pop-up calendar. It collects Year, Month and Day and allows end date but it's not required. "Cache dates" is disabled. No limit to the amount of values.
Comment #3
BrightBold@ordermind - you forgot to set the status back to active so Karen will know you've updated the issue.
I'm about to upgrade Date on a multilingual site so I'll post if I experience this problem.
Comment #4
inak CreditAttribution: inak commentedsame issue with german language. (Feb is working but Mar is not).
Mar works if you change it manually to Mär.
Comment #5
kristiaanvandeneyndeSubscribing and confirming for Dutch.
18 mrt 2012 is valid, while the pop-up enters 18 Mar 2012 into the text field.
Because my locale is set to Dutch, the automatically entered date won't validate.
Setting to normal according to priority conventions.
Comment #6
drzraf CreditAttribution: drzraf commentedhard to believe but this is true,
I can confirm this in french, 14 dec 2011 won't work while 14 déc 2011 will.
Comment #7
drzraf CreditAttribution: drzraf commentedProbably caused by this 2 years old bug #775876: Datepicker better local/localization/i18n/language support
will try to find a workaround.
Comment #8
drzraf CreditAttribution: drzraf commentedroughly, see the attached patch.
But it's worst than that because in french, the localized datepicker provides "Déc.", but sadly
"Déc.", "Déc", "déc." won't work, only "déc" will.
Comment #9
drzraf CreditAttribution: drzraf commentedI think that the bare minimum would be, in the field instance settings, to hide all date/time formats which are known to be buggy when
$language
!= 'en'.Comment #10
AbilioLemos CreditAttribution: AbilioLemos commentedI can confirm the same issue for spanish...
Comment #11
gynekolog CreditAttribution: gynekolog commenteddrzraf: Thank you!
Comment #12
Saisai CreditAttribution: Saisai commentedalso in dutch..
Comment #13
MediaFormat CreditAttribution: MediaFormat commentedSubscribing.
Having the same issue here, again with French.
What exactly does the patch do?
Comment #14
gynekolog CreditAttribution: gynekolog commenteddjungle: apply patch, download jquery.ui.datepicker for your language (from https://jquery-ui.googlecode.com/svn/tags/1.8.7/ui/i18n/) and move to date_popup folder.
Comment #15
Vasiliy Grotov CreditAttribution: Vasiliy Grotov commentedCan't validate date field on russian language.
Patch didn't help me.
Comment #16
arlinsandbulte CreditAttribution: arlinsandbulte commentedNot sure if this is really related or not, but Karen put the following on the Date Project page:
That issue is: #507502: (needs documentation) Provide Locale support for jQuery UI
Comment #17
Vasiliy Grotov CreditAttribution: Vasiliy Grotov commentedThank you, arlinsandbulte.
I've already put my eye on this. But that didn't did the trick.
Comment #18
KarenS CreditAttribution: KarenS commentedNote that you have to use the patch that is linked to on the project page. There are other patches in that thread but the linked one is for the D7 version and later ones are for D8 and won't work.
I can't replicate any problem when using the right patch. If there is still a problem using that specific patch (http://drupal.org/node/507502#comment-4534106), I need confirmation that that is the patch that was used, that you cleared caches after applying the patch, and that it still is broken after that, along with specific steps to reproduce this on a clean install.
Comment #19
drasgardian CreditAttribution: drasgardian commentedThat patch is for the jquery datepicker, but I don't think this issue stems from the datepicker. Using text field as the widget I still experience "The value input for field Review Date is invalid: The month is missing." in Russian.
My short date format is set to d M Y g:ia and granularity on the field is set to year + month + day
Comment #20
drasgardian CreditAttribution: drasgardian commentedTesting from a clean drupal 7 install:
Added the date, locale, l10n_update modules.
Added russian as a second language
Added a date field to the page content type with year + month + day granularity and text field widget
Added the date format d M Y g:ia and configured the date field to use that format
Set the translation detection settings to allow url (i.e. /ru/...)
Went to /ru/node/add/page
First thing I noticed was that the help text beneath the field that shows the example format said "Формат: 23 Apr 2012". So the month there wasn't being translated.
If I enter an english date (23 Apr 2012) or a russian date (23 Apn 2012) both get rejection during validation with the message:
"The value input for field date test is invalid:
The month is missing."
The easiest workaround of course is to simply set the field's input format to something nice and easy like 23/04/2012, turn on the datepicker and then apply the patch described above to get the datepicker localized.
Comment #21
knalstaaf CreditAttribution: knalstaaf commentedPlease don't underestimate this issue. I lost a lot of time with it and owed my client some explanation for the delay.
I didn't have that much nodes to correct following the instructions above (which is the only workaround so far). If I'd had 60 nodes of the type suffering this issue, it would have been really sh*te.
Bad news still is: I have to apply the workaround for three similar websites. So I'm holding my breath here.
Comment #22
kristiaanvandeneyndeGood news for this issue: #507502: (needs documentation) Provide Locale support for jQuery UI is about to be fixed in D7 (already has in D8)
Comment #23
wemmies CreditAttribution: wemmies commentedyes, patch works for me. http://drupal.org/node/507502#comment-6111240 507502-129-with-calendar-popup-at-authoring-date-D7.patch
Comment #24
drasgardian CreditAttribution: drasgardian commentedI don't think #507502 can fix this issue (although it might bypass it), because this issue exists even when not using a jquery date widget. See my comment in #19.
Comment #25
kristiaanvandeneyndeJudging by comment #2, this issue is about the datepicker.
If there is another l11n issue going on, you could create a separate issue describing it and perhaps link to this one?
Comment #26
wemmies CreditAttribution: wemmies commentedI believe it does, isn't the validation of the textfield also done via datepicker / jquery?
Comment #27
KarenS CreditAttribution: KarenS commentedThe core issue, #507502: (needs documentation) Provide Locale support for jQuery UI, has now been committed. That fix is not in the 7.14 release, you have to pick up the dev release of core until a 7.15 release is cut.
With that, I have no problems using the popup widget to insert translated date values and the format displays the date correctly as well, at least when using a language that has all the date elements translated.
The problem of capitalization if you want both 'Dec' and 'dec' to work interchangeably can't be fixed. The translator translated the value using the lower case, so that's the only value the system can understand. If you want uppercase you have to fix the translation, which is outside my control. So long as you use the value as it was translated (i.e. the way it is displayed in the popup widget and the format example), things work for me.
There is a separate issue about validation at #1596546: When using a format of d M Y errors are not reported for invalid months, which I think is the only remaining issue. At least it's the only remaining issue that I can do anything about.
If someone thinks there is still a problem after using the corrected version of core, you'll have to provide more details.
Comment #28
KarenS CreditAttribution: KarenS commentedAnd for comment #20, it's possible the Russian translation is missing a translation for 'Apr'.
Comment #29
KarenS CreditAttribution: KarenS commentedOK, found a couple more fixes -- things that used to work fine but gotten broken when the UI was updated earlier this year. With this I'm not seeing any more problems.
http://drupalcode.org/project/date.git/commit/cadc9c1
Comment #31
Karthick Krthck CreditAttribution: Karthick Krthck commented