xref: /template/sprintdoc/main.php (revision c58aab2fe385055ddf45902c81ccf27ae91e1779)
1<!DOCTYPE html>
2<?php
3
4/**
5 * DokuWiki sprintDoc Template
6 *
7 * @link     FIXME
8 * @author   Jana Deutschlaender <deutschlaender@cosmocode.de>
9 * @license  GPL 2 (http://www.gnu.org/licenses/gpl.html)
10 */
11
12if (!defined('DOKU_INC')) die();                        /* must be run from within DokuWiki */
13@require_once(dirname(__FILE__).'/tpl_functions.php');  /* include hook for template functions */
14header('X-UA-Compatible: IE=edge,chrome=1');
15
16$showTools = !tpl_getConf('hideTools') || ( tpl_getConf('hideTools') && !empty($_SERVER['REMOTE_USER']) );
17$showSidebar = page_findnearest($conf['sidebar']) && ($ACT=='show');
18
19
20/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
21/* conditional comments for IE8 / IE9 browser detection if needed */
22/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
23?>
24<!--[if lt IE 9]> <html class="no-js lt-ie10 lt-ie9" lang="<?php echo $conf['lang'] ?>" dir="<?php echo $lang['direction'] ?>"> <![endif]-->
25<!--[if IE 9]> <html class="no-js lt-ie10 ie-9" lang="<?php echo $conf['lang'] ?>" dir="<?php echo $lang['direction'] ?>"> <![endif]-->
26<!--[if gt IE 9]><!--> <html class="edge no-js" lang="<?php echo $conf['lang'] ?>" dir="<?php echo $lang['direction'] ?>"> <!--<![endif]-->
27<head>
28
29<?php
30
31
32/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
33/* meta and link relations */
34/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
35?>
36<meta charset="utf-8" />
37<meta name="viewport" content="width=device-width, initial-scale=1.0" />
38<?php tpl_metaheaders() ?>
39<?php
40
41
42/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
43/* conditional comments for HTML5 / media queries support in IE8 */
44/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
45?>
46<!--[if lt IE 9]>
47    <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
48    <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
49<![endif]-->
50
51<?php
52
53
54/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
55/* page title */
56/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
57?>
58<title><?php tpl_pagetitle() ?> [<?php echo strip_tags($conf['title']) ?>]</title>
59
60<script type="text/javascript">(function(H){H.className=H.className.replace(/\bno-js\b/,'js')})(document.documentElement)</script>
61
62<?php
63
64
65/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
66/* favicons */
67/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
68?>
69<?php
70    echo tpl_favicon(array('favicon')); /* DokuWiki: favicon.ico  */
71    include('tpl/favicon_tiles.php');
72?>
73<?php
74
75
76/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
77/* Include Hook: meta.html */
78/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
79?>
80<?php tpl_includeFile('meta.html') ?>
81</head>
82<?php /* #dokuwiki__top used as anchor for "back to top" button/link links */ ?>
83<body id="dokuwiki__top" class="<?php echo tpl_classes(); ?>">
84
85
86    <div id="dokuwiki__site">
87        <?php
88
89
90/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
91/* template Include: tpl/nav-direct */
92/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
93        ?>
94        <?php include('tpl/nav-direct.php') ?>
95
96
97        <div class="page-wrapper <?php echo ($showSidebar) ? 'hasSidebar' : ''; ?>">
98            <?php
99
100
101/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
102/* Message AREA */
103/* FIXME: position of error + info messages. Does it have to be on top of the page? */
104/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
105            html_msgarea();
106
107
108/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
109/* MagicMatcher */
110/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
111            ?>
112
113            <div id="dokuwiki_magic-matcher" class="magic-matcher no-print">
114                <div class="container">
115                    <?php
116                        $mm = plugin_load('helper', 'magicmatcher_context');
117                        if($mm){
118                            $mm->tpl();
119                        }
120                    ?>
121                </div><!-- .container -->
122            </div><!-- .magic-matcher -->
123            <?php
124
125/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
126/* Include Hook: header.html */
127/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
128            tpl_includeFile('header.html');
129
130/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
131/* Header */
132/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
133            ?>
134
135            <div id="dokuwiki__header" class="header no-print">
136                <div class="container">
137                    <div class="row">
138                        <?php if ($conf['useacl'] && $showTools): ?>
139
140                            <nav id="dokuwiki__usertools">
141                                <h6 class="sr-only" role="heading" aria-level="2"><?php echo $lang['user_tools']; ?></h6>
142                                <ul>
143                                    <?php
144                                    if (!empty($_SERVER['REMOTE_USER'])) {
145                                        echo '<li class="user"><span class="sr-only">'.$lang['loggedinas'].' </span>'.userlink().'</li>';
146                                    }?>
147                                    <li class="log"><?php tpl_actionlink('login'); ?></li>
148
149                                    <?php tpl_toolsevent('usertools', array(
150                                        'admin'     => tpl_action('admin', 1, 'li', 1),
151                                        'userpage'  => _tpl_action('userpage', 1, 'li', 1),
152                                        'profile'   => tpl_action('profile', 1, 'li', 1),
153                                        'register'  => tpl_action('register', 1, 'li', 1),
154                                    )); ?>
155
156                                </ul>
157                            </nav><!-- #dokuwiki__usertools -->
158                        <?php endif ?>
159
160                    </div>
161                </div><!-- .container -->
162
163            <div class="headings">
164                <h1><?php tpl_link(wl(),$conf['title'],'accesskey="h" title="[H]"') ?></h1>
165                <?php /* how to insert logo instead (if no CSS image replacement technique is used):
166                        upload your logo into the data/media folder (root of the media manager) and replace 'logo.png' accordingly:
167                        tpl_link(wl(),'<img src="'.ml('logo.png').'" alt="'.$conf['title'].'" />','id="dokuwiki__top" accesskey="h" title="[H]"') */ ?>
168                <?php if ($conf['tagline']): ?>
169                    <p class="claim"><?php echo $conf['tagline'] ?></p>
170                <?php endif ?>
171
172
173                <div class="clearer"></div>
174            </div>
175
176            <div class="tools">
177
178                <!-- SITE TOOLS -->
179                <div id="dokuwiki__sitetools">
180                    <h3 class="a11y"><?php echo $lang['site_tools'] ?></h3>
181                    <?php tpl_searchform() ?>
182                    <ul>
183                        <?php tpl_toolsevent('sitetools', array(
184                            'recent'    => tpl_action('recent', 1, 'li', 1),
185                            'media'     => tpl_action('media', 1, 'li', 1),
186                            'index'     => tpl_action('index', 1, 'li', 1),
187                        )); ?>
188                    </ul>
189                </div>
190
191            </div>
192            <div class="clearer"></div>
193
194            <!-- BREADCRUMBS -->
195            <?php if($conf['breadcrumbs']){ ?>
196                <div class="breadcrumbs"><?php tpl_breadcrumbs() ?></div>
197            <?php } ?>
198            <?php if($conf['youarehere']){ ?>
199                <div class="breadcrumbs"><?php tpl_youarehere() ?></div>
200            <?php } ?>
201
202            <div class="clearer"></div>
203            <hr class="a11y" />
204        </div></div><!-- /header -->
205
206
207        <div class="wrapper">
208
209            <!-- ********** ASIDE ********** -->
210            <?php if ($showSidebar): ?>
211                <div id="dokuwiki__aside"><div class="pad aside include group">
212                    <?php tpl_includeFile('sidebarheader.html') ?>
213                    <?php tpl_include_page($conf['sidebar'], 1, 1) /* includes the nearest sidebar page */ ?>
214                    <?php tpl_includeFile('sidebarfooter.html') ?>
215                    <div class="clearer"></div>
216                </div></div><!-- /aside -->
217            <?php endif; ?>
218
219            <!-- ********** CONTENT ********** -->
220            <div id="dokuwiki__content"><div class="pad">
221                <?php tpl_flush() /* flush the output buffer */ ?>
222                <?php tpl_includeFile('pageheader.html') ?>
223
224                <div class="page">
225                    <!-- wikipage start -->
226                    <?php tpl_content() /* the main content */ ?>
227                    <!-- wikipage stop -->
228                    <div class="clearer"></div>
229                </div>
230
231                <?php tpl_flush() ?>
232                <?php tpl_includeFile('pagefooter.html') ?>
233            </div></div><!-- /content -->
234
235            <div class="clearer"></div>
236            <hr class="a11y" />
237
238            <!-- PAGE ACTIONS -->
239            <?php if ($showTools): ?>
240                <div id="dokuwiki__pagetools">
241                    <h3 class="a11y"><?php echo $lang['page_tools'] ?></h3>
242                    <ul>
243                        <?php tpl_toolsevent('pagetools', array(
244                            'edit'      => tpl_action('edit', 1, 'li', 1),
245                            'discussion'=> _tpl_action('discussion', 1, 'li', 1),
246                            'revisions' => tpl_action('revisions', 1, 'li', 1),
247                            'backlink'  => tpl_action('backlink', 1, 'li', 1),
248                            'subscribe' => tpl_action('subscribe', 1, 'li', 1),
249                            'revert'    => tpl_action('revert', 1, 'li', 1),
250                            'top'       => tpl_action('top', 1, 'li', 1),
251                        )); ?>
252                    </ul>
253                </div>
254            <?php endif; ?>
255        </div><!-- /wrapper -->
256
257        <!-- ********** FOOTER ********** -->
258        <div id="dokuwiki__footer"><div class="pad">
259            <div class="doc"><?php tpl_pageinfo() /* 'Last modified' etc */ ?></div>
260            <?php tpl_license('button') /* content license, parameters: img=*badge|button|0, imgonly=*0|1, return=*0|1 */ ?>
261        </div></div><!-- /footer -->
262
263        <?php tpl_includeFile('footer.html') ?>
264    </div><!-- .dokuwiki__site -->
265
266    <div class="no"><?php tpl_indexerWebBug() /* provide DokuWiki housekeeping, required in all templates */ ?></div>
267
268</body>
269</html>
270