2007-06-30 01:19:11 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
class RegenThumbTheme extends Themelet {
|
2007-07-28 20:30:01 +00:00
|
|
|
/*
|
|
|
|
* Show a form which offers to regenerate the thumb of an image with ID #$image_id
|
|
|
|
*/
|
2007-06-30 01:19:11 +00:00
|
|
|
public function display_buttons($page, $image_id) {
|
|
|
|
$html = "
|
|
|
|
<form action='".make_link("regen_thumb")."' method='POST'>
|
|
|
|
<input type='hidden' name='image_id' value='$image_id'>
|
|
|
|
<input type='submit' value='Regenerate'>
|
|
|
|
</form>
|
|
|
|
";
|
|
|
|
$page->add_block(new Block("Regen Thumb", $html, "left"));
|
|
|
|
}
|
|
|
|
|
2007-07-28 20:30:01 +00:00
|
|
|
/*
|
|
|
|
* Show a link to the new thumbnail
|
|
|
|
*/
|
2007-06-30 01:19:11 +00:00
|
|
|
public function display_results($page, $image) {
|
|
|
|
$page->set_title("Thumbnail Regenerated");
|
|
|
|
$page->set_heading("Thumbnail Regenerated");
|
|
|
|
$page->add_header("<meta http-equiv=\"cache-control\" content=\"no-cache\">");
|
|
|
|
$page->add_block(new NavBlock());
|
2007-10-26 01:35:53 +00:00
|
|
|
$page->add_block(new Block("Thumbnail", $this->build_thumb_html($image)));
|
2007-06-30 01:19:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
?>
|