I'm calling jAlert with this function
$('.stcommentdelete').live("click",function() {
var ID = $(this).attr("id");
var dataString 开发者_开发技巧= 'com_id='+ ID;
jConfirm('Oled sa kindel, et tahad kustutada??', '', function(r){
if(r==true){
$.ajax({
type: "POST",
url: "delete_comment_ajax.php",
data: dataString,
cache: false,
success: function(html){
$("#stcommentbody"+ID).slideUp();
}
});
}
});
});
If i have for example 15 comments and i would delete last comment, it scrolls up. But i need that it stays focused on this place where i delete comment.
Omerimuni
I found what was wrong in my script. I called this script from link like a href="#". I remove href="#" and it works. :D Sry for bother u guys ;)
精彩评论