Merge pull request #450 from DakuTree/patch-zipcheck
Hide "Download All Images" if ZipArchive doesn't exist/not enabled - Fixes #441
This commit is contained in:
commit
565b466721
2 changed files with 3 additions and 2 deletions
|
@ -17,7 +17,7 @@
|
||||||
* <br>Download the contents of the database in plain text format, useful
|
* <br>Download the contents of the database in plain text format, useful
|
||||||
* for backups.
|
* for backups.
|
||||||
* <p>Image dump:
|
* <p>Image dump:
|
||||||
* <br>Download all the images as a .zip file
|
* <br>Download all the images as a .zip file (Requires ZipArchive)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -45,7 +45,8 @@ class AdminPageTheme extends Themelet {
|
||||||
$html = "";
|
$html = "";
|
||||||
$html .= $this->button("All tags to lowercase", "lowercase_all_tags", true);
|
$html .= $this->button("All tags to lowercase", "lowercase_all_tags", true);
|
||||||
$html .= $this->button("Recount tag use", "recount_tag_use", false);
|
$html .= $this->button("Recount tag use", "recount_tag_use", false);
|
||||||
$html .= $this->button("Download all images", "download_all_images", false);
|
if(class_exists('ZipArchive'))
|
||||||
|
$html .= $this->button("Download all images", "download_all_images", false);
|
||||||
$html .= $this->button("Download database contents", "database_dump", false);
|
$html .= $this->button("Download database contents", "database_dump", false);
|
||||||
if($database->get_driver_name() == "mysql")
|
if($database->get_driver_name() == "mysql")
|
||||||
$html .= $this->button("Reset image IDs", "reset_image_ids", true);
|
$html .= $this->button("Reset image IDs", "reset_image_ids", true);
|
||||||
|
|
Reference in a new issue