Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update serializeForm.js #9

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

adardesign
Copy link

Allow callback to process the values.. 

formEle.serializeForm(function (val) {
   return encodeURIComponent(val);
}));

Allow callback to process the values.. 
form.serializeForm(function (val) {
            return encodeURIComponent(val);
        }));
@adardesign
Copy link
Author

Thanks for your explanation!
I don't agree on your point regarding that "it's easy to modify values once you get them from serializeForm" because why iterate twice on the object/array..
But I do agree on your point on where i placed the code, and to also pass in the index, also i would suggest to pass in the name (key) too..

Take a look at https://gist.github.com/adardesign/5091258

let me know if I should modify/refactor my pull request and what you think.

Thanks again!

@danheberden
Copy link
Owner

I'm ok with this going in as long as the edits are made above. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants