Şimdiye kadar, ben aşağıdaki var:
$.getJSON('getinfo.php', { id:id }, parseInfo);
function parseInfo(data) {
$('div#info').fadeOut("fast", function() {
$('div#info').html(data.desc);
}
}
Ben div # bilgi html etiketinin içinde sonuçları (data.desc) yazdırmak mümkün duyuyorum, ama ben bunu daha önce, benim php fonksiyonu ile data.desc biçimlendirmek istiyoruz. Yani, temelde böyle bir şey yapmak istiyorum,
function parseInfo(data) {
$('div#info').fadeOut("fast", function() {
<?php
$formated = some_php_function(data.desc);
?>
$('div#info').html(<?php echo $formated ?>);
}
}