summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/controllers/welcome.php8
-rw-r--r--core/views/welcome.html.php5
2 files changed, 12 insertions, 1 deletions
diff --git a/core/controllers/welcome.php b/core/controllers/welcome.php
index adce7443..1c90842c 100644
--- a/core/controllers/welcome.php
+++ b/core/controllers/welcome.php
@@ -24,6 +24,14 @@ class Welcome_Controller extends Template_Controller {
$this->template->syscheck = new View("welcome_syscheck.html");
$this->template->syscheck->errors = $this->_get_config_errors();
$this->template->syscheck->modules = $this->_read_modules();
+ $this->template->album_count = 0;
+ $this->template->photo_count = 0;
+ try {
+ $this->template->album_count = ORM::factory("item")->where("type", "album")->count_all();
+ $this->template->photo_count = ORM::factory("item")->where("type", "photo")->count_all();
+ } catch (Exception $e) {
+ }
+
$this->_create_directories();
}
diff --git a/core/views/welcome.html.php b/core/views/welcome.html.php
index 680f0aa6..28e18023 100644
--- a/core/views/welcome.html.php
+++ b/core/views/welcome.html.php
@@ -148,7 +148,10 @@
</div>
<div id="actions" class="activity">
- <p> <?= html::anchor("album/1", "Browse Gallery") ?> </p>
+ <p>
+ <?= html::anchor("album/1", "Browse Gallery") ?>
+ <i>(<?= $album_count ?> albums, <?= $photo_count ?> photos)</i>
+ </p>
<ul class="choices">
<li> add: [</li>
<? foreach (array(1, 10, 50, 100, 500, 1000) as $count): ?>