summaryrefslogtreecommitdiff
path: root/js/quick-reply.js
diff options
context:
space:
mode:
authorMichael Foster <savetheinternet@tinyboard.org>2013-09-15 14:03:27 +1000
committerMichael Foster <savetheinternet@tinyboard.org>2013-09-15 14:03:27 +1000
commit00833eeafd6e0f71390504ac10ddf86bbaceb39f (patch)
tree2ca84516f2b7d44efe88b9aa2e609bef0dd32fd7 /js/quick-reply.js
parentfd5300a49e67f9401b821404a146b338bc21dd8a (diff)
js/ajax.js: post with ajax
Diffstat (limited to 'js/quick-reply.js')
-rw-r--r--js/quick-reply.js9
1 files changed, 8 insertions, 1 deletions
diff --git a/js/quick-reply.js b/js/quick-reply.js
index 824286f6..5f81f51e 100644
--- a/js/quick-reply.js
+++ b/js/quick-reply.js
@@ -123,6 +123,9 @@ var show_quick_reply = function(){
}
// Move anti-spam nonsense and remove <th>
+ $th.contents().filter(function() {
+ return this.nodeType == 3; // Node.TEXT_NODE
+ }).remove();
$th.contents().appendTo($dummyStuff);
$th.remove();
@@ -180,7 +183,9 @@ var show_quick_reply = function(){
});
$postForm.find('textarea[name="body"]').removeAttr('id').removeAttr('cols').attr('placeholder', _('Comment'));
-
+
+ $postForm.find('textarea:not([name="body"]),input[type="hidden"]').appendTo($dummyStuff);
+
$postForm.find('br').remove();
$postForm.find('table').prepend('<tr><th colspan="2">' + _('Quick Reply') + '</th></tr>');
@@ -232,6 +237,8 @@ var show_quick_reply = function(){
}
$postForm.show();
+ $(window).trigger('quick-reply');
+
$origPostForm = $('form[name="post"]');
$(window).ready(function() {