I am getting the jsong response from php backend like
feedback = {"html":"<form action='someurlonrest' method='post' style='margin-left:100px;' ><div style='padding: 10px;'>Ticket No<input type='text' id='tkt' name='tkt' ><\/div><div style='padding: 10px;'>somthing <input type='text' id='smthing' name='smthing' ><\/div><div style='padding: 10px;'>Query about <input type='text' id='query' name='query' ><\/div><input type='submit' class='classname' ><\/form>"}
why i am getting undefined message whenever i am trying to do
alert(feedback.html);
Updated
function get_fb_success(){
var feedback = $.ajax({
type: "POST",
url: "feedback.php",
async: false
}).success(function(){
setTimeout(function(){get_fb_success();}, 100000000000000000);
}).responseText;
alert(feedback);
//$('#log_success').val('');
$('#log_success').html(feedback.html);
//$('div.feedback-box-success').html('success feedback');
}
The answer to your question is that you can see the object value you are looking for. See the fiddle here: http://jsfiddle.net/aWC8G/
Below that, your ajax function looks a little strange. I think it should look like this:
Of course is is not an asynchronous call to the server, if you want real async ajax, do it like this (which should work since your function is not actually returning any value: