diff options
| author | Chad Kieffer <ckieffer@gmail.com> | 2011-01-04 15:59:26 -0700 |
|---|---|---|
| committer | Chad Kieffer <ckieffer@gmail.com> | 2011-01-04 15:59:26 -0700 |
| commit | e921c3c5b5b8f963f121601d346c50a24bc0cf15 (patch) | |
| tree | a29064762c3b37812596cb82c3e910f7321a85b2 /modules/gallery/controllers/photos.php | |
| parent | dbff45cc91ac44f18ef02b8abdd220a2864f050f (diff) | |
| parent | d74aad072d8ccca70efb1c8b673e8368566a1974 (diff) | |
Merge branch 'master' of git://github.com/gallery/gallery3
Diffstat (limited to 'modules/gallery/controllers/photos.php')
| -rw-r--r-- | modules/gallery/controllers/photos.php | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/modules/gallery/controllers/photos.php b/modules/gallery/controllers/photos.php index b22ac8e5..d500a92e 100644 --- a/modules/gallery/controllers/photos.php +++ b/modules/gallery/controllers/photos.php @@ -38,19 +38,19 @@ class Photos_Controller extends Items_Controller { } $template = new Theme_View("page.html", "item", "photo"); - $template->set_global("item", $photo); - $template->set_global("children", array()); - $template->set_global("children_count", 0); - $template->set_global("parents", $photo->parents()->as_array()); - $template->set_global("next_item", $next_item); - $template->set_global("previous_item", $previous_item); - $template->set_global("sibling_count", $photo->parent()->viewable()->children_count($where)); - $template->set_global("position", $position); + $template->set_global( + array("item" => $photo, + "children" => array(), + "children_count" => 0, + "parents" => $photo->parents()->as_array(), + "next_item" => $next_item, + "previous_item" => $previous_item, + "sibling_count" => $photo->parent()->viewable()->children_count($where), + "position" => $position)); $template->content = new View("photo.html"); - $photo->view_count++; - $photo->save(); + $photo->increment_view_count(); print $template; } |
