From d48e85e0ac5e675ca33fac173f30c75403d1033f Mon Sep 17 00:00:00 2001 From: donncha Date: Thu, 22 Jun 2006 18:31:50 +0000 Subject: Moved everything in wp-inst down a directory. Uses's Ryan Boren's htaccess rules and mods If you're upgrading, try this on a test server first! git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@591 7be80a69-a1ef-0310-a953-fb0f7c49ff36 --- wp-admin/edit-comments.js | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 wp-admin/edit-comments.js (limited to 'wp-admin/edit-comments.js') diff --git a/wp-admin/edit-comments.js b/wp-admin/edit-comments.js new file mode 100644 index 0000000..4dfe755 --- /dev/null +++ b/wp-admin/edit-comments.js @@ -0,0 +1,23 @@ +addLoadEvent(function() { + theCommentList = new listMan('the-comment-list'); + if ( !theCommentList ) + return false; + theCommentList.dimComplete = function(what,id,dimClass) { + var m = document.getElementById('awaitmod'); + if ( document.getElementById(what + '-' + id).className.match(dimClass) ) m.innerHTML = parseInt(m.innerHTML,10) + 1; + else m.innerHTML = parseInt(m.innerHTML,10) - 1; + } + theCommentList.delComplete = function(what,id) { + var m = document.getElementById('awaitmod'); + if ( document.getElementById(what + '-' + id).className.match('unapproved') ) m.innerHTML = parseInt(m.innerHTML,10) - 1; + } + if ( theList ) // the post list: edit.php + theList.delComplete = function() { + var comments = document.getElementById('comments'); + var commdel = encloseFunc(function(a){a.parentNode.removeChild(a);},comments); + var listdel = encloseFunc(function(a){a.parentNode.removeChild(a);},theCommentList.theList); + setTimeout(commdel,705); + setTimeout(listdel,705); + } +}); + -- cgit