$('#textButton, #imgButton').live('click', function(){
id_button = $(this).attr('id');
$.ajax({
url: '/sys/app/layouts/addText.php',
success: function(data) {
if(id_button == 'textButton'){
$('#text').html(data);
$('#imgButton').empty();
} else{
$('#img').html(data);
$('#text').hide();
}
}
});