]> git.bts.cx Git - garden.git/blobdiff - templates/base.php
Added template fallback support
[garden.git] / templates / base.php
index 76d6d0081e24b154860f8903484802b6521c65e8..5a6a7435dc8be4d26dd0b4bea559201a438bf005 100644 (file)
@@ -13,7 +13,9 @@
                <meta name="viewport" content="width=device-width, initial-scale=1.0">
 
                <link rel="stylesheet" href="<?= garden_site_url('style', 'screen.css') ?>">
+
                <link rel="alternate" type="application/atom+xml" href="<?= garden_site_url('feed.atom') ?>">
+               <link rel="alternate" type="application/feed+json" href="<?= garden_site_url('feed.json') ?>">
        </head>
 
        <body>
                                        <?php endif ?>
                                <?php endforeach ?>
                                </ul>
+
+                               <ul>
+                                       <?php if (defined('GARDEN_ATOM_FEED_FILENAME')): ?>
+                                       <li><a href="<?= garden_site_url(GARDEN_ATOM_FEED_FILENAME) ?>" class="feed">Atom Feed</a></li>
+                                       <?php endif ?>
+
+                                       <?php if (defined('GARDEN_JSON_FEED_FILENAME')): ?>
+                                       <li><a href="<?= garden_site_url(GARDEN_JSON_FEED_FILENAME) ?>" class="feed">JSON Feed</a></li>
+                                       <?php endif ?>
+                               </ul>
+
+                               <?php if (isset($sidebar_links)): ?>
+                               <ul>
+                                       <?php foreach ($sidebar_links as $link): ?>
+                                               <li><a href="<?= $link['url'] ?>"><?= $link['text'] ?></a></li>
+                                       <?php endforeach ?>
+                               </ul>
+                               <?php endif ?>
                        </nav>
 
                        <?= garden_template_content(); ?>