index: replace our custom result listing page with an album preview

This commit is contained in:
mappu 2017-11-18 14:11:40 +13:00
parent 08321818ff
commit 3a103ae484
1 changed files with 1 additions and 17 deletions

View File

@ -56,23 +56,7 @@ $.get("/about", function(ret) {
// Load upload widget
contented.init("#surrogate-area", function(items) {
var $table = $("<table>");
for (var i = 0; i < items.length; ++i) {
$table.append($("<tr>").append([
$("<td>").append($("<img>").attr('src', contented.getThumbnailURL(contented.thumbnail.small_square, items[i]))),
$("<td>").text(items[i]),
$("<td>").html("<a target='_blank' href='" + contented.getDownloadURL(items[i]) + "'>get</a>"),
$("<td>").html("<a target='_blank' href='" + contented.getInfoJSONURL(items[i]) + "'>info</a>"),
]))
}
$("#surrogate-area").html([
$table,
$("<button>").addClass("again").text("Again...").click(function() {
window.location.href = window.location.href;
}),
]);
window.location.href = contented.getMultiPreviewURL(items);
});
</script>
</body>