From fa9dda4c01a1ebb1af34e51fb36c2b3f27eb8d6e Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Mon, 3 Nov 2008 05:55:34 +0000 Subject: Create an initial attempt at the album controller, set it up with a default route and add a link to it from the welcome page. --- core/config/config.php | 2 ++ core/config/routes.php | 22 ++++++++++++++++++++++ core/controllers/album.php | 45 +++++++++++++++++++++++++++++++++++++++++++++ core/views/welcome.html.php | 1 + 4 files changed, 70 insertions(+) create mode 100644 core/config/routes.php create mode 100644 core/controllers/album.php (limited to 'core') diff --git a/core/config/config.php b/core/config/config.php index afa84a82..5ab35a0e 100644 --- a/core/config/config.php +++ b/core/config/config.php @@ -122,4 +122,6 @@ $config['modules'] = array MODPATH . 'unit_test', MODPATH . 'mptt', MODPATH . 'forge', + + THEMEPATH . 'default', ); diff --git a/core/config/routes.php b/core/config/routes.php new file mode 100644 index 00000000..5314d913 --- /dev/null +++ b/core/config/routes.php @@ -0,0 +1,22 @@ +where("id", $id)->find(); + if (empty($item->id)) { + return Kohana::show_404(); + } + $this->template->item = $item; + + $this->template->header = new View("page_header.html"); + $this->template->header->item = $item; + + $this->template->footer = new View("page_footer.html"); + $this->template->footer->item = $item; + + $this->template->content = new View("album.html"); + $this->template->content->item = $item; + $this->template->content->maxRows = 3; + $this->template->content->maxColumns = 3; + + $this->template->sidebar = new View("page_sidebar.html"); + $this->template->sidebar->item = $item; + + } +} diff --git a/core/views/welcome.html.php b/core/views/welcome.html.php index 51bc72e8..adea7543 100644 --- a/core/views/welcome.html.php +++ b/core/views/welcome.html.php @@ -88,6 +88,7 @@

Activities

+

Documentation

-- cgit v1.2.3