Closed nolantait closed 2 months ago
I had the same issue last week and would also vote for mentioning it in the README
Does it make sense for this value to be the default? In theory it works for forms with or without files. What’s the downside to this being enabled by default?
If there is an issue enabling this by default, it might be possible to detect when a file field is used to automatically set the form to this encoding type.
Regardless, I agree this should be in the docs.
GET based form semantics would be ruined and it would bloat the size of your requests slightly from what I can gather online.
I was thinking of flagging the field when the methods are called but it would require people implementing their own fields to call super or flag it themselves. Same problem if we just add introspection for the types as it depends on controlling the input calls.
Ah that would be bad if the GET semantics were ruined.
Seems like docs is the way to go.
Just opened a PR with a potential addition to the docs
Full error is:
This can be fixed by adding the
enctype
attribute tomultipart/form-data
:Maybe for now putting a note into the README? Can't think of an obvious way of passing this back up to the
around_template
call. Maybe introspecting the form in that method?