Hello everyone,

For some reason the American date format is not accepted in my form. I 
wonder if any Django developer from US could help me with this. I suspect 
the timezone in the settings also affect the date format, but I am not sure.

*Settings:*

TIME_ZONE = 'Europe/London'
LANGUAGE_CODE = 'en-us'
USE_I18N = True
USE_L10N = True
USE_TZ = True

*ModelForm:*

class CallsForm(ModelForm):    
   class Meta:
        model = Conversation   
        widgets = {
                    'contact_date': forms.DateInput(attrs={'placeholder': 'Add 
the date...', 'id': 'datepicker', 'class': 'placeholder_fix_css'}, 
format='%m/%d/%Y'),
                   }

[image: enter image description here]

Any idea why the American Dateformat still isn't accepted?

Many Thanks,
Houman

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/django-users/-/uuMUxpVhbx4J.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to