#23075: Type-specific input fields cause cross-browser issues and wrong error
messages
-----------------------------+------------------------------------
     Reporter:  sehmaschine  |                    Owner:  nobody
         Type:  Bug          |                   Status:  new
    Component:  Forms        |                  Version:  1.7-rc-1
     Severity:  Normal       |               Resolution:
     Keywords:               |             Triage Stage:  Accepted
    Has patch:  1            |      Needs documentation:  0
  Needs tests:  0            |  Patch needs improvement:  0
Easy pickings:  0            |                    UI/UX:  0
-----------------------------+------------------------------------
Changes (by erikr):

 * has_patch:  0 => 1


Comment:

 I created https://github.com/django/django/pull/3105 in which I've
 implemented the last solution I suggested in the mailing list thread:

   I've had another look at this. The novalidate attribute on the form for
 URL and email fields indeed disables the validation in both Chrome and
 Safari. For number fields, I can reproduce Patrick's test: Safari will
 still silently drop the value.

   So, for URL and email fields, this issue is resolved by setting
 novalidate on the form. I think we should document a recommendation for
 users to add this attribute to their forms, and change the forms in the
 admin to always include the novalidate attribute, as Bruno suggested.

   This does not resolve the issue of Safari silently discarding invalid
 numbers. I don't see a way to resolve that, other than to revert to the
 text field. Perhaps this is a Safari bug. I haven't managed to find a
 standard on what browsers should be doing in this case, but this behaviour
 seems awful. But even if it is a Safari bug, that wouldn't fix the issue
 for a while anyways. Overall, I'd rather go for the partial novalidate
 solution for now, than do nothing at all.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/23075#comment:9>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/069.c48e2fd868bdfc2e3c0487efafb9c560%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to