"; } /** * Show a link to the new thumbnail. */ public function display_results(Page $page, Image $image) { $page->set_title("Thumbnail Regenerated"); $page->set_heading("Thumbnail Regenerated"); $page->add_html_header(""); $page->add_block(new NavBlock()); $page->add_block(new Block("Thumbnail", $this->build_thumb_html($image))); } public function mtr_html(string $terms) { $h_terms = html_escape($terms); $html = make_form(make_link("regen_thumb/mass"), "POST") . " "; return $html; } public function bulk_html() { return ""; } public function display_admin_block() { global $page, $database; $types = []; $results = $database->get_all("SELECT ext, count(*) count FROM images group by ext"); foreach ($results as $result) { array_push($types, ""); } $html = " Will only regenerate missing thumbnails, unless force is selected. Force will override the limit and will likely take a very long time to process.

".make_form(make_link("admin/regen_thumbs"))."

".make_form(make_link("admin/delete_thumbs"), "POST", false, "", "return confirm('Are you sure you want to delete all thumbnails?')")."

"; $page->add_block(new Block("Regen Thumbnails", $html)); } }