Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

add parameter to serialize javascript

var data = $(this).serializeArray(); // convert form to array
data.push({name: "NonFormValue", value: NonFormValue});
$.ajax({
    type: 'POST',
    url: this.action,
    data: $.param(data),
});
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #add #parameter #serialize #javascript
ADD COMMENT
Topic
Name
2+3 =