/,'').replace(/\<\/g\>.*/,'').replace(/^[A-z ,]{4,5}/,'').replace(/,.*/,''));
+ return d1 < d2 ? 1 : -1;
+ });
+ $('End of sorting. Posts without timestamps:
').insertAfter($('#thread_top'));
+ sorted.detach().insertAfter($('#thread_top'));
+ if (sorted[0] != first)
+ $(first).detach().insertBefore(sorted[0]);
+ })
+ );
+ $('#thread').append(
+ $('')
+ .attr('href','javascript:void(0)')
+ .html(' Delete All')
+ .click(function(){
+ if (confirm('Are you sure you want delete all posts that you currently see?')) {
+ $('.glyphicon-trash').click();
+ }
+ })
+ );
+
+ addPost(post, function(d){ d.appendTo($('#thread')); }, false, false);
+ if (_depth == 1) arr.reverse();
+ for (var i = 0; i < arr.length; i++) {
+ var deleted = Base64.decode(arr[i].message) == _postWasDeletedMarker;
+ if (_showDeleted == 'false' && deleted) continue;
+ var p = addPost(arr[i], function(d) {d.appendTo($('#thread'));}, true)
+ if (p){
+ p.css('margin-left', _treeOffsetPx + 'px');
+ if (deleted) p.css({ opacity: _deletedOpacity});
+ if (highlight == arr[i].hash) {
+ p.addTemporaryClass('high', 8000);
+ }
+ if (_depth > 1) {
+ loadReplies(arr[i].hash, 2, highlight);
+ }
+ }
+ }
+ vid_show()
+ });
+ });
+}
\ No newline at end of file