Is it possible to send input via ajax to a php script and have the success callback .load a section of the already displayed page and have a php script inside the reloaded section display a SESSION variable inside the label of the input?
EDIT: So this is the script I feel like was implemented wrong what errors would you have me fix?
$(document).ready(function() {
$('input1').on('keypress',function(e){
var p = e.which;
if(p==13){
var input1set = $(this);
var input1 = input1set.serialize();
$.ajax({
url:'inputs.php',
type: 'post',
data: input1,
success: function(input1) {
$('#input1lable').load("tables/table_1.php #input1lable");
}
});
return false;
});
// this is the repeatable input field code.
});
So where did I go Wrong?
P.S I hope there is enough context already given to know how this is working in my APP.