How to convert jquery collection to xml string for an ajax request
- by Jim
I created a jquery collection that stores xml as follows:
var rh_request = $('')
.attr('user_id', user_id)
.attr('company_id', company_id)
.attr('action', 'x');
I want to post it to my server via an ajax request as follows:
$.ajax({
type: "POST",
url: mywebsiteURL,
processData: false,
dataType: "xml",
data: rh_request.html(),
success:…