Opened 15 years ago
Closed 13 years ago
#512 closed enhancement (wontfix)
[patch][need cla] make encodeForm use per-type serialization functions
Reported by: | ningu | Owned by: | James Burke |
---|---|---|---|
Priority: | high | Milestone: | 0.9 |
Component: | General | Version: | 0.3 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
In my applications I use XMLHTTP-submitted forms frequently, but I prefer to make one small change to how the params are normally submitted -- I make checkboxes always submit 1 or 0, which simplifies handling them on the server end. There is no single thing to override in dojo to create this behavior. I've made a small patch to do so. encodeForm() now chooses its appropriate serializer from dojo.io.formEncodeSerializer[type]. This also allows further customization of form submissions if there is e.g. something special about how you want to handle select-one, or whatever. I've left the image stuff the same cause I wasn't sure what to do with it.
Attachments (1)
Change History (11)
Changed 15 years ago by
comment:1 Changed 15 years ago by
Milestone: | → 0.3release |
---|
comment:2 Changed 15 years ago by
Milestone: | 0.3release → 0.4 |
---|
comment:3 Changed 14 years ago by
No CLA on file as far as I can tell, so we can't merge this patch.
comment:4 Changed 14 years ago by
Summary: | make encodeForm use per-type serialization functions → [patch][needs cla] make encodeForm use per-type serialization functions |
---|
Pushing to next release because we still haven't received a response to our CLA requirement.
comment:5 Changed 14 years ago by
Summary: | [patch][needs cla] make encodeForm use per-type serialization functions → [patch][need cla] make encodeForm use per-type serialization functions |
---|
comment:6 Changed 14 years ago by
Owner: | changed from anonymous to alex |
---|
comment:7 Changed 14 years ago by
Owner: | changed from alex to jkuhnert |
---|---|
Status: | new → assigned |
comment:9 Changed 14 years ago by
Owner: | changed from jkuhnert to James Burke |
---|---|
Status: | assigned → new |
Re-assigning to james for a minimum of at least getting his thoughts on how this should be handled.
Besides not the not having a cla part, do you even want to see formbind go in this direction?
comment:10 Changed 13 years ago by
Resolution: | → wontfix |
---|---|
Status: | new → closed |
No CLA, and there is no form bind in 0.9. Closing this as wontfix since the approach has changed in 0.9.
There is dojo.formToObject, which I do not think should allow special serializers, but instead, use dojo.formToObject to get a JS object representing form values, then you can manipulate that object however you want before serializing.
hi ningu, do we have a CLA on file for you?
If not, would you mind filling one out? http://dojotoolkit.org/icla.txt
Regards