diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/gallery/libraries/Admin_View.php | 10 | ||||
-rw-r--r-- | modules/gallery/libraries/Theme_View.php | 10 | ||||
-rw-r--r-- | modules/search/controllers/search.php | 8 | ||||
-rw-r--r-- | modules/tag/controllers/tag.php | 12 |
4 files changed, 20 insertions, 20 deletions
diff --git a/modules/gallery/libraries/Admin_View.php b/modules/gallery/libraries/Admin_View.php index bff13ace..28a003cc 100644 --- a/modules/gallery/libraries/Admin_View.php +++ b/modules/gallery/libraries/Admin_View.php @@ -34,11 +34,11 @@ class Admin_View_Core extends Gallery_View { $this->theme_name = Input::instance()->get("theme", $this->theme_name); } $this->sidebar = ""; - $this->set_global("theme", $this); - $this->set_global("user", identity::active_user()); - $this->set_global("page_type", "admin"); - $this->set_global("page_subtype", $name); - $this->set_global("page_title", null); + $this->set_global(array("theme" => $this, + "user" => identity::active_user(), + "page_type" => "admin", + "page_subtype" => $name, + "page_title" => null)); } public function admin_menu() { diff --git a/modules/gallery/libraries/Theme_View.php b/modules/gallery/libraries/Theme_View.php index d22bb03a..ba1862c0 100644 --- a/modules/gallery/libraries/Theme_View.php +++ b/modules/gallery/libraries/Theme_View.php @@ -37,11 +37,11 @@ class Theme_View_Core extends Gallery_View { } $this->item = null; $this->tag = null; - $this->set_global("theme", $this); - $this->set_global("user", identity::active_user()); - $this->set_global("page_type", $page_type); - $this->set_global("page_subtype", $page_subtype); - $this->set_global("page_title", null); + $this->set_global(array("theme" => $this, + "user" => identity::active_user(), + "page_type" => $page_type, + "page_subtype" => $page_subtype, + "page_title" => null)); if ($page_type == "collection") { $this->set_global("thumb_proportion", $this->thumb_proportion()); } diff --git a/modules/search/controllers/search.php b/modules/search/controllers/search.php index e5894f30..733bc9f7 100644 --- a/modules/search/controllers/search.php +++ b/modules/search/controllers/search.php @@ -34,10 +34,10 @@ class Search_Controller extends Controller { $max_pages = max(ceil($count / $page_size), 1); $template = new Theme_View("page.html", "collection", "search"); - $template->set_global("page", $page); - $template->set_global("max_pages", $max_pages); - $template->set_global("page_size", $page_size); - $template->set_global("children_count", $count); + $template->set_global(array("page" => $page, + "max_pages" => $max_pages, + "page_size" => $page_size, + "children_count" => $count)); $template->content = new View("search.html"); $template->content->items = $result; diff --git a/modules/tag/controllers/tag.php b/modules/tag/controllers/tag.php index 0e924f3d..7bfa7d58 100644 --- a/modules/tag/controllers/tag.php +++ b/modules/tag/controllers/tag.php @@ -35,12 +35,12 @@ class Tag_Controller extends Controller { } $template = new Theme_View("page.html", "collection", "tag"); - $template->set_global("page", $page); - $template->set_global("max_pages", $max_pages); - $template->set_global("page_size", $page_size); - $template->set_global("tag", $tag); - $template->set_global("children", $tag->items($page_size, $offset)); - $template->set_global("children_count", $children_count); + $template->set_global(array("page" => $page, + "max_pages" => $max_pages, + "page_size" => $page_size, + "tag" => $tag, + "children" => $tag->items($page_size, $offset), + "children_count" => $children_count)); $template->content = new View("dynamic.html"); $template->content->title = t("Tag: %tag_name", array("tag_name" => $tag->name)); |