summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2009-09-12 20:46:54 -0700
committerBharat Mediratta <bharat@menalto.com>2009-09-12 20:46:54 -0700
commit711cdde5b9755140981000adc6dd7897d836ccc5 (patch)
tree51013edda2048421b84fbe75de86db0f5b85d45c
parent823fa2fc8339a6638ef4f0fcdae7f96e99a4f0bd (diff)
Only tack ?show=<current_id> on for the last parent, because that's
the only parent for which the id is relevant. In a perfect world each parent's link would have a ?show=<id> for the next child's id. But that would require some confusing code and I don't want to put that into the default/example theme yet.
-rw-r--r--themes/default/views/page.html.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/themes/default/views/page.html.php b/themes/default/views/page.html.php
index 733534ea..19d8cc00 100644
--- a/themes/default/views/page.html.php
+++ b/themes/default/views/page.html.php
@@ -95,7 +95,12 @@
<ul class="gBreadcrumbs">
<? foreach ($parents as $parent): ?>
<li>
- <a href="<?= $parent->url("show={$theme->item()->id}") ?>">
+ <!-- Adding ?show=<id> causes Gallery3 to display the page
+ containing that photo. For now, we just do it for
+ the immediate parent so that when you go back up a
+ level you're on the right page. -->
+ <a href="<?= $parent->url($parent == $theme->item()->parent() ?
+ "show={$theme->item()->id}" : null) ?>">
<?= html::purify($parent->title) ?>
</a>
</li>