#3297: newforms: Implement FileField and ImageField
---------------------------------------+------------------------------------
Reporter: [EMAIL PROTECTED] | Owner: adrian
Status: reopened | Component: django.newforms
Version: SVN | Resolution:
Keywords: newforms | Stage: Ready for
checkin
Has_patch: 1 | Needs_docs: 0
Needs_tests: 0 | Needs_better_patch: 0
---------------------------------------+------------------------------------
Comment (by David Danier <[EMAIL PROTECTED]>):
The 4700-patch has the problems stated in comment #31. It relies on user-
input (the second form-field) to do validation. This is not clean and can
lead to validation-problems.
As the djangoboook says:
"Never under any circumstances trust data from the browser."
(http://www.djangobook.com/en/beta/chapter20/)
4722 does mostly the same, but custom Forms need to set required to False
on (already provided) FileField's itself. And of course it skips the
additional hidden form-field, so I think the above error might be caused
by some mixture of the old forms (or old patch) and the rewritten one. ->
There is no check for the hidden field anymore.
Please consider adding 4722, as newforms is a good place to remove such
unclean things from the code.
Btw.: I think both patches do not apply against the current trunk. I will
provide an updated patch soon.
--
Ticket URL: <http://code.djangoproject.com/ticket/3297#comment:43>
Django Code <http://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 post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---