In the application I am working, the server pages are used to recieving an input's name as the key for it's value. Is is possible to do this with ajax? In this example, thisName is treated as a literal string.
$('table').each(function(){
$(this).delegate("input", "focusout", function(){
var thisValue = $(this).val();
var thisName = $(this).attr('name');
$.ajax({
timeout: 3000,
//cache: false,
data: {
p_session_id: $("[name='p_session_id']").val(),
p_username: $("[name='p_username']").val(),
thisName: thisValue
// ^^
},
success: function(data){
alert( data )
}
});
});