1<?php
2/**
3 * DokuWiki sprintDoc Detail Template
4 *
5 * @link     FIXME
6 * @author   Jana Deutschlaender <deutschlaender@cosmocode.de>
7 * @author   Michael Grosse <grosse@cosmocode.de>
8 * @license  GPL 2 (http://www.gnu.org/licenses/gpl.html)
9 */
10use dokuwiki\template\sprintdoc\Template;
11
12if (!defined('DOKU_INC')) die();                        /* must be run from within DokuWiki */
13header('X-UA-Compatible: IE=edge,chrome=1');
14
15global $JSINFO;
16if (empty($JSINFO['template'])) {
17    $JSINFO['template'] = array();
18}
19$JSINFO['template']['sprintdoc'] = array('sidebar_toggle_elements' => tpl_getConf('sidebar_sections'));
20
21$showTools = true;
22$showSidebar =  true;
23
24?>
25<!DOCTYPE html>
26<html class="edge no-js" lang="<?php echo $conf['lang'] ?>" dir="<?php echo $lang['direction'] ?>">
27<head>
28<?php
29
30
31/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
32/* meta and link relations */
33/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
34?>
35<meta charset="utf-8" />
36<meta name="viewport" content="width=device-width, initial-scale=1.0" />
37<?php tpl_metaheaders() ?>
38<?php
39
40
41/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
42/* page title */
43/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
44?>
45<title><?php echo hsc(tpl_img_getTag('IPTC.Headline', $IMG)) ?> [<?php echo strip_tags($conf['title']) ?>]</title>
46
47<script type="text/javascript">(function(H){H.className=H.className.replace(/\bno-js\b/,'js')})(document.documentElement)</script>
48<?php
49
50
51/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
52/* favicons */
53/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
54?>
55<?php
56include('tpl/favicon_tiles.php');
57?>
58<?php
59
60
61/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
62/* Include Hook: meta.html */
63/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
64?>
65<?php tpl_includeFile('meta.html') ?>
66</head>
67
68<body id="dokuwiki__top" class="<?php echo tpl_classes(); ?> wide-content showSidebar <?php echo tpl_getConf('header_layout'); ?>">
69<div id="dokuwiki__site">
70    <?php
71
72
73/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
74/* template Include: tpl/nav-direct */
75/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
76    ?>
77    <?php include('tpl/nav-direct.php') ?>
78
79
80    <div class="page-wrapper <?php echo ($showSidebar) ? 'hasSidebar' : ''; ?>">
81        <?php
82
83
84/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
85/* Include Hook: header.html */
86/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
87            tpl_includeFile('header.html');
88        ?>
89
90        <div id="dokuwiki__header" class="header no-print">
91            <div class="container">
92                <div class="row">
93                    <div class="col-xs-12">
94                        <div class="claim main-sidebar">
95                            <div class="menu-togglelink mobile-only">
96                                <a href="#">
97                                    <span class="sr-out"><?php echo tpl_getLang('a11y_sidebartoggle'); ?></span>
98                                </a>
99                            </div>
100
101                            <?php
102
103
104/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
105/* Logo */
106/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
107/* upload your logo into the data/media folder (root of the media manager) and replace 'logo.png' in der template config accordingly: */
108                                include('tpl/main-sidebar-logo.php');
109                            ?>
110                            <div class="main-title">
111                                <?php if ($conf['title']):
112
113
114/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
115/* Wiki Title Mobile */
116/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */ ?>
117                                    <p class="title mobile-only"><?php echo $conf['title'] ?></p>
118                                <?php endif ?>
119                            </div><!-- .main-title -->
120
121                            <div class="menu-tool-select">
122                                <h5 class="sr-only" role="heading" aria-level="2"><?php echo tpl_getLang('head_menu_tool-select') ?></h5>
123                                <?php tpl_actiondropdown($lang['tools'], "test"); ?>
124                            </div><!-- .menu-tool-select -->
125                        </div><!-- .headings -->
126                    </div><!-- .col -->
127
128
129                    <div class="col-xs-12">
130                        <div class="main-title desktop-only">
131                            <?php if ($conf['title']):
132
133
134/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
135/* Wiki Title Desktop */
136/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */ ?>
137                                <p class="title"><?php echo $conf['title'] ?></p>
138                            <?php endif ?>
139                            <?php if ($conf['tagline']):
140
141
142/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
143/* Wiki Tagline Desktop */
144/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */ ?>
145                                <p class="claim"><?php echo $conf['tagline'] ?></p>
146                            <?php endif ?>
147                        </div><!-- .main-title -->
148                    </div><!-- .col -->
149
150                </div><!-- .row -->
151            </div><!-- .container -->
152        </div><!-- .header -->
153        <?php
154
155
156/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
157/* headline menu area (Accessibility ) */
158/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
159        ?>
160
161        <div class="sr-only nav-area-head">
162            <h5 class="sr-only" aria-level="1"><?php echo tpl_getLang('nav-area-head') ?></h5>
163        </div><!-- .nav-area-head -->
164
165        <div class="tools">
166            <div class="container">
167                <div class="row">
168                    <div class="col-xs-12">
169                        <div class="search main-sidebar">
170                            <?php
171
172
173/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
174/* search form */
175/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
176                                include('tpl/main-sidebar-search.php');
177                            ?>
178                        </div><!-- .search -->
179
180                        <div class="sidebarheader main-sidebar">
181                            <?php
182
183
184/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
185/* Include Hook: sidebarheader.html */
186/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
187                                tpl_includeFile('sidebarheader.html')
188                            ?>
189                        </div><!-- .sidebarheader -->
190
191                        <div id="dokuwiki__aside">
192
193                            <?php
194                            echo Template::getInstance()->getInclude(
195                                'sidebarheader',
196                                '<div class="sidebarheader">',
197                                '<div class="clearer"></div></div>'
198                            );
199                            ?>
200
201                            <?php
202
203
204/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
205/* sidebar */
206/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
207                                include('tpl/main-sidebar-nav.php');
208                            ?>
209
210                            <?php
211                            echo Template::getInstance()->getInclude(
212                                'sidebarfooter',
213                                '<div class="sidebarfooter">',
214                                '<div class="clearer"></div></div>'
215                            );
216                            ?>
217                        </div><!-- .aside -->
218
219                    </div><!-- .col -->
220                </div><!-- .row -->
221            </div><!-- .container -->
222        </div><!-- .tools -->
223
224
225        <div class="top-header">
226            <div class="container">
227                <div class="row">
228                    <div class="col-xs-12">
229
230                        <?php
231
232
233/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
234/* User Tools but no MagicMatcher Bar */
235/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
236                        $showTools = true;
237                        include('tpl/nav-usertools-buttons.php');
238
239
240/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
241/* Include Hook: header.html */
242/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
243                        tpl_includeFile('header.html');
244                        ?>
245
246                    </div><!-- .col -->
247                </div><!-- .row -->
248            </div><!-- .container -->
249        </div><!-- /top-header -->
250
251
252        <div id="dokuwiki__detail">
253
254            <?php tpl_flush(); /* flush the output buffer */ ?>
255
256            <div class="content group">
257                <div class="container">
258                    <div class="row">
259                        <div class="col-xs-12">
260                            <div class="breadcrumbs" data-do="<?php echo tpl_getLang('image_detail') ?>">
261
262                                <div class="togglelink page_main-content">
263                                    <a id="spr__toggle-content" href="#"><span class="sr-out"><?php echo tpl_getLang('a11y_sidebartoggle') ?></span></a>
264                                </div>
265
266                                <h6 class="sr-only" role="heading" aria-level="2"><?php echo tpl_getLang('head_menu_status') ?></h6>
267
268                                <?php
269
270
271/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
272/* breadcrumb */
273/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
274                                include('tpl/nav-breadcrumb.php');
275                                ?>
276
277                                <h6 class="sr-only" role="heading" aria-level="2"><?php echo $lang['page_tools'] ?></h6>
278
279                                <?php
280
281
282/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
283/* page tools */
284/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
285                                ?>
286                                <nav id="dokuwiki__pagetools">
287                                    <div class="tools">
288                                        <ul>
289                                            <?php
290                                            echo '<li>' . dokuwiki\template\sprintdoc\tpl::pageToolAction('mediaManager') . '</li>';
291                                            echo '<li>' . dokuwiki\template\sprintdoc\tpl::pageToolAction('img_backto') . '</li>';
292                                            ?>
293                                        </ul>
294                                    </div>
295                                </nav>
296
297                            </div>
298                            <div id="dokuwiki__content" class="page main-content">
299
300                                <div id="spr__meta-box"></div>
301                                <div class="msg-area"><?php html_msgarea();/*msg('Information.', 0);msg('Success', 1);msg('Notification', 2);msg('Fehler', -1);*/ ?></div>
302
303
304                                <?php if ($ERROR): print $ERROR; ?>
305                                <?php else: ?>
306
307                                <?php if ($REV) {
308                                    echo p_locale_xhtml('showrev');
309                                } ?>
310
311                                <h1><?php echo hsc(tpl_img_getTag('IPTC.Headline', $IMG)) ?></h1>
312                                <?php
313
314
315/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
316/* image */
317/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
318                                ?>
319                                <div class="img-link">
320                                    <?php tpl_img(900, 700); /* the image; parameters: maximum width, maximum height (and more) */ ?>
321                                </div>
322                                <?php
323
324
325/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
326/* meta data of image */
327/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
328                                ?>
329                                <div class="img_detail">
330                                    <?php
331                                        $simple_title = hsc(tpl_img_getTag('simple.title'));
332                                        if(strlen($simple_title) > 0) {
333                                    ?>
334                                    <h4><?php print nl2br(hsc(tpl_img_getTag('simple.title'))); ?></h4>
335                                    <?php
336                                        } else {
337                                            echo '<h4>' . tpl_getLang('meta_data') . '</h4>';
338                                        }
339                                    ?>
340
341                                    <?php
342                                    tpl_img_meta();
343
344
345/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
346/* open street maps if geo data is available */
347/* + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + */
348                                    /** @var \helper_plugin_spatialhelper_index $spatial */
349                                    $spatial = plugin_load('helper', 'spatialhelper_index');
350                                    if ($spatial && plugin_load('helper', 'geophp')) {
351                                        global $IMG;
352                                        $point = $spatial->getCoordsFromExif($IMG);
353                                        if ($point) {
354                                            $long = $point->getX();
355                                            $lat = $point->getY();
356                                            $latShort = round($lat, 3);
357                                            $longShort = round($long, 3);
358
359                                            $hrefOSM = "https://www.openstreetmap.org/?mlat=$lat&mlon=$long#map=18/$lat/$long";
360                                            $srcOSM = 'https://www.openstreetmap.org/export/embed.html?bbox=' . ($long - 0.004) . ',' . ($lat - 0.002) . ',' . ($long + 0.004) . ',' . ($lat + 0.002) . '&layer=mapnik&marker=' . $lat . ',' . $long;
361                                            echo '<div class="os-map">';
362                                            echo '<h4 lang="en">OSM (Open Street Maps):</h4>';
363                                            echo '<iframe width="100%" height="350" frameborder="0" src="' . $srcOSM . '"></iframe><br/><p><a class="button" target="_blank" title="' . tpl_getLang('osm_zoom_link_title') . '" href="' . $hrefOSM . '">' . tpl_getLang('osm_zoom_link_text') . '</a></p>';
364                                            echo '</div>';
365                                        }
366                                    }
367                                    ?>
368                                    <?php //Comment in for Debug// dbg(tpl_img_getTag('Simple.Raw')); ?>
369                                </div>
370                            </div><!-- .main-content -->
371                        </div><!-- .col -->
372                    </div><!-- .row -->
373                </div><!-- .container -->
374            </div><!-- /.content -->
375
376
377        <?php endif; ?>
378        </div>
379    </div><!-- /wrapper -->
380
381
382    <!-- ********** FOOTER ********** -->
383
384    <div id="dokuwiki__footer">
385        <div class="container">
386            <div class="row">
387                <div class="col-xs-12">
388
389                    <div class="main-footer">
390                        <?php include 'tpl/main-footer.php'; ?>
391                    </div>
392
393                </div>
394            </div>
395        </div>
396    </div><!-- /footer -->
397
398
399    <?php tpl_includeFile('footer.html') ?>
400</div><!-- .dokuwiki__site -->
401
402<div class="no"><?php tpl_indexerWebBug() /* provide DokuWiki housekeeping, required in all templates */ ?></div>
403
404</body>
405</html>
406