Feature Req: on/off button for auto-reload js #1 Fix insertafter selector so that new post gets autoloaded with the correct formatting and spacing.

This commit is contained in:
Benjamin Southall 2017-03-13 19:02:22 +09:00
parent ad935a1aef
commit 2fae551db7

View File

@ -236,7 +236,7 @@ $(document).ready(function(){
var n = new Notification("New reply to "+$('title').text(), {body: $('<div/>').html(body).text()}); var n = new Notification("New reply to "+$('title').text(), {body: $('<div/>').html(body).text()});
} }
} }
$(this).insertAfter($('div.post:not(.post-hover):last')).after('<br class="clear">'); $(this).parent().insertAfter($('div.post:not(.post-hover):last').parent().next()).after('<br class="clear">');
new_posts++; new_posts++;
loaded_posts++; loaded_posts++;
$(document).trigger('new_post', this); $(document).trigger('new_post', this);