From a897a9d53f7df79f55888141444a22f38665dce6 Mon Sep 17 00:00:00 2001 From: Chad Kieffer Date: Thu, 6 Jan 2011 21:00:28 -0700 Subject: Also missed commiting this in a1e3b1ed17177cf7e0ef. --- modules/info/helpers/info_block.php | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) (limited to 'modules/info') diff --git a/modules/info/helpers/info_block.php b/modules/info/helpers/info_block.php index 064c73b2..5841ec6f 100644 --- a/modules/info/helpers/info_block.php +++ b/modules/info/helpers/info_block.php @@ -31,29 +31,31 @@ class info_block_Core { $block->css_id = "g-metadata"; $block->title = $theme->item()->is_album() ? t("Album info") : t("Photo info"); $block->content = new View("info_block.html"); - $info["title"] = array( - "label" => t("Title:"), - "value" => html::purify($theme->item->title) - ); - if ($theme->item->description) { + if ($theme->item->title && module::get_var("info", "show_title")) { + $info["title"] = array( + "label" => t("Title:"), + "value" => html::purify($theme->item->title) + ); + } + if ($theme->item->description && module::get_var("info", "show_description")) { $info["description"] = array( "label" => t("Description:"), "value" => nl2br(html::purify($theme->item->description)) ); } - if (!$theme->item->is_album()) { + if (!$theme->item->is_album() && module::get_var("info", "show_name")) { $info["file_name"] = array( "label" => t("File name:"), "value" => html::clean($theme->item->name) ); } - if ($theme->item->captured) { + if ($theme->item->captured && module::get_var("info", "show_captured")) { $info["captured"] = array( "label" => t("Captured:"), "value" => gallery::date_time($theme->item->captured) ); } - if ($theme->item->owner) { + if ($theme->item->owner && module::get_var("info", "show_owner")) { $display_name = $theme->item->owner->display_name(); if ($theme->item->owner->url) { $info["owner"] = array( -- cgit v1.2.3