1<?php
2/**
3 * DokuWiki Bootstrap3 Template: Footer page
4 *
5 * @link     http://dokuwiki.org/template:bootstrap3
6 * @author   Giuseppe Di Terlizzi <giuseppe.diterlizzi@gmail.com>
7 * @license  GPL 2 (http://www.gnu.org/licenses/gpl.html)
8 */
9
10global $conf;
11global $TPL;
12
13$footer_page_exist    = page_findnearest('footer', $TPL->getConf('useACL'));
14$license_is_enabled   = $conf['license'];
15$badges_is_enabled    = $TPL->getConf('showBadges');
16$wiki_info_is_enabled = $TPL->getConf('showWikiInfo');
17
18$logo_size      = array();
19$wiki_logo      = tpl_getMediaFile(array(':wiki:logo.png', ':logo.png', 'images/logo.png'), false, $logo_size);
20$wiki_title     = $conf['title'];
21$wiki_tagline   = ($conf['tagline']) ? '<span class="dw__tagline">'.$conf['tagline'].'</span>' : '';
22$wiki_home_link = ($TPL->getConf('homePageURL') ? $TPL->getConf('homePageURL') : wl());
23
24?>
25<?php if ($wiki_info_is_enabled || $footer_page_exist || $license_is_enabled || $badges_is_enabled): ?>
26<!-- footer -->
27<div class="dw-container small container<?php echo ($TPL->getConf('fixedTopNavbar') || $TPL->isFluidNavbar() ? '-fluid mx-5' : '') ?>">
28
29
30    <div class="footer-dw-title">
31        <?php if ($wiki_info_is_enabled): ?>
32        <div class="media">
33            <div class="media-left">
34                <img src="<?php echo $wiki_logo ?>" alt="<?php echo $wiki_title ?>" class="media-object" style="height:32px" />
35            </div>
36            <div class="media-body">
37                <div class="row">
38                    <div class="col-sm-2">
39                        <h4 class="media-heading"><?php echo $wiki_title ?></h4>
40                        <p>
41                            <?php echo $wiki_tagline ?>
42                        </p>
43                    </div>
44                    <div class="col-sm-10">
45                        <?php
46                            if ($footer_page_exist) {
47                                echo $TPL->includePage('footer');
48                            }
49                        ?>
50                    </div>
51                </div>
52            </div>
53        </div>
54        <?php endif; ?>
55        <?php
56            if (! $wiki_info_is_enabled && $footer_page_exist) {
57                echo $TPL->includePage('footer');
58            }
59        ?>
60    </div>
61
62    <div class="footer-license row">
63        <hr/>
64        <div id="dw__license" class="col-sm-6">
65            <?php if ($license_is_enabled): ?>
66            <p>
67                <?php $TPL->getLicense('image') ?>
68            </p>
69            <p class="small">
70                <?php $TPL->getLicense('link') ?>
71            </p>
72            <?php endif; ?>
73        </div>
74
75        <div class="col-sm-6">
76            <?php
77                if ($badges_is_enabled) {
78                    require_once('badges.php');
79                }
80            ?>
81        </div>
82
83    </div>
84
85</div>
86<!-- /footer -->
87<?php endif; ?>
88