[js] $(document).ready(function(){
$('#submit').click(function(){
var title = $('#title').val();
var author = $('#author').val();
var text = $('#text').val();
$.post('<?= site_url('Welcome/addComment')?>',{ title: title, author: author, text: text },function(){
$('#info').load('<?= site_url('Welcome/viewComment')?>');
$('#title').val('');
$('#author').val('');
$('#text').val('');
})
});
});[/js]
$('#submit').click(function(){
var title = $('#title').val();
var author = $('#author').val();
var text = $('#text').val();
$.post('<?= site_url('Welcome/addComment')?>',{ title: title, author: author, text: text },function(){
$('#info').load('<?= site_url('Welcome/viewComment')?>');
$('#title').val('');
$('#author').val('');
$('#text').val('');
})
});
});[/js]