Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $('.comment-delete').click(function(e){
- var commentId = $(this).attr('comment-id');
- var data={commentId:commentId,method:'Delete'}
- $.ajax(
- {
- url:'/post/comment/'+commentId,
- type: 'DELETE',
- dataType: "JSON",
- data: data,
- success: function ()
- {
- $('#comment-block-'+commentId).fadeOut("slow");
- Command: toastr["success"]("Comment deleted !!! ", "Success..")
- toastr.options = {
- "closeButton": false,
- "debug": false,
- "newestOnTop": false,
- "progressBar": false,
- "positionClass": "toast-bottom-right",
- "preventDuplicates": false,
- "onclick": null,
- "showDuration": "300",
- "hideDuration": "1000",
- "timeOut": "5000",
- "extendedTimeOut": "1000",
- "showEasing": "swing",
- "hideEasing": "linear",
- "showMethod": "fadeIn",
- "hideMethod": "fadeOut"
- }
- }
- });
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement