Something like this would get the labels and values
jQuery(document).ready(function($){
$('input[name="add_custom_search"]').click(function(){
var obj = {};
$( ".searchdetails label").each(function(i, el) {
obj[$(el).text()] = $(el).next().val();
});
$.ajax({
url : '/path/to/myurl.php',
data : obj
}).done(function(data) {
console.log(data);
}).fail(function(a,b,c) {
console.log(a,b,c)
});
});
});
But if you're going to just send it to the serverside, $('form').serialize()
seems a lot easier.
Note that the form will submit and the page reload when you click the button unless you prevent the default behaviour, and that most times listening for the forms submit event is better than the submit buttons click event.