1<?php
2/**
3	* DokuWiki Default Template
4 *
5 * This is the template you need to change for the overall look
6 * of DokuWiki.
7 *
8 * You should leave the doctype at the very top - It should
9 * always be the very first line of a document.
10 *
11 * @link   http://dokuwiki.org/templates
12 * @author Andreas Gohr <andi@splitbrain.org>
13 */
14
15// must be run from within DokuWiki
16if (!defined('DOKU_INC')) die();
17if (!defined('DOKU_TPL')) define('DOKU_TPL',tpl_basedir());
18
19    function _hide_email($email) {
20          $encode = '';
21          for ($x=0; $x < strlen($email); $x++) $encode .= '&#x' . bin2hex($email{$x}).';';
22          return $encode;
23    }
24
25?>
26<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
27 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
28<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $conf['lang']?>"
29 lang="<?php echo $conf['lang']?>" dir="<?php echo $lang['direction']?>">
30<head>
31  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
32  <title>
33    <?php tpl_pagetitle()?>
34    [<?php echo strip_tags($conf['title'])?>]
35  </title>
36
37 <?php
38$bypass_sidebar = false;
39$pages =tpl_getConf('sbar_closed');
40$sidebar_off = tpl_getConf('sidebar_off');
41if($sidebar_off) {
42    $bypass_sidebar=true;
43
44}
45else if($pages) {
46    global $ID;
47    if(preg_match('/' . $ID .'/',$pages)) {
48       $bypass_sidebar=true;
49    }
50}
51 global $INPUT;
52 $current_class = $INPUT->str('do');
53if(($current_class && $current_class == 'admin')  || $bypass_sidebar) {
54       echo  "<style type = 'text/css'>#toggler{ display: none; } </style>";
55       $current_class="ssb_admin";
56 }
57 else {
58     $current_class="ssb_std";
59 }
60 ?>
61
62  <?php tpl_metaheaders()?>
63
64  <link rel="shortcut icon" href="<?php echo DOKU_TPL?>images/favicon.ico" />
65
66  <?php /*old includehook*/ @include(dirname(__FILE__).'/meta.html')?>
67</head>
68
69<body>
70<?php /*old includehook*/ @include(dirname(__FILE__).'/topheader.html')?>
71
72<!--  TOP BAR -->
73
74<div id="top_bar" class="dokuwiki  <?php echo $current_class;?>">
75
76  <?php html_msgarea()?>
77
78  <div class="stylehead">
79
80    <div class="header">
81      <div class="pagename">
82        [[<?php tpl_link(wl($ID,'do=backlink'),tpl_pagetitle($ID,true),'title="'.$lang['btn_backlink'].'"')?>]]
83      </div>
84      <div class="logo">
85        <?php tpl_link(wl(),$conf['title'],'name="dokuwiki__top" id="dokuwiki__top" accesskey="h" title="[H]"')?>
86      </div>
87
88      <div class="clearer"></div>
89    </div>  <!-- header -->
90
91    <?php /*old includehook*/ @include(dirname(__FILE__).'/header.html')?>
92
93    <div class="bar" id="bar__top">
94      <div class="bar-left" id="bar__topleft">
95        <?php tpl_button('edit')?>
96        <?php tpl_button('history')?>
97      </div>
98
99      <div class="bar-right" id="bar__topright">
100        <?php tpl_button('recent')?>
101        <?php tpl_searchform()?>&nbsp;
102      </div>
103      <div class="clearer"></div>
104    </div>  <!-- bar__top -->
105    <?php if($conf['breadcrumbs']){?>
106    <div class="breadcrumbs">
107      <?php tpl_breadcrumbs()?>
108      <?php //tpl_youarehere() //(some people prefer this)?>
109    </div>
110    <?php }?>
111
112    <?php if($conf['youarehere']){?>
113    <div class="breadcrumbs">
114      <?php tpl_youarehere() ?>
115    </div>
116    <?php }?>
117
118  </div> <!-- stylehead -->
119
120  <?php flush()?>
121
122  <?php /*old includehook*/ @include(dirname(__FILE__).'/pageheader.html')?>
123</div> <!--top_bar-->
124
125<!--  TOP BAR END -->
126
127<!--  WRAPPER START-->
128<div id="wrapper">
129<div id="main_page" class="dokuwiki">
130<div id="toggler">
131<a href="javascript:sbar_toggler.toggle();void 0"><img src="<?php echo DOKU_TPL?>images/toggle.png" title="toggle" border="0" /></a>
132</div>
133<div class="left_sidebar <?php echo $current_class;?>"  id="left_sidebar">
134
135<?php
136	$ssbar = dirname(__FILE__).'/sidebar.html';
137	if(file_exists($ssbar)) {
138	@include($ssbar);
139	}
140	else {
141	  $ssbar = dirname(__FILE__).'/sidebar.php';
142	  if(file_exists($ssbar)) {
143	     @include($ssbar);
144	  }
145	 }
146?>
147<div id="personal_ssb">
148<?php
149 global $INFO;
150$pageid = "sidebar:" . $INFO['client'];
151tpl_include_page($pageid);
152?>
153</div>
154</div>  <!-- end left_sidebar-->
155
156  <div class="page">
157 <div class="right_page <?php echo $current_class;?>"  id="right_page">
158
159    <!-- wikipage start -->
160    <?php tpl_content()?>
161    <!-- wikipage stop -->
162  </div>  <!-- right_page-->
163  </div>  <!-- page -->
164
165
166  <div class="clearer">&nbsp;</div>
167
168  <?php flush()?>
169
170 <div class="stylefoot  <?php echo $current_class;?>" id="bottom_div">
171
172
173      <div class="meta">
174        <?php tpl_userinfo()?>  <?php tpl_pageinfo()?>&nbsp;&nbsp;
175      </div>
176
177
178
179   <?php /*old includehook*/ @include(dirname(__FILE__).'/pagefooter.html')?>
180   <br />
181    <div class="bar  <?php echo $current_class;?>" id="bar__bottom">
182      <div class="bar-left" id="bar__bottomleft">
183        <?php tpl_button('edit')?>
184        <?php
185          global $updateVersion;
186          if($updateVersion >= 35) {
187             tpl_button('media');
188          }
189        ?>
190        <?php tpl_button('subscribe')?>
191        <?php tpl_button('admin')?>
192        <?php tpl_button('profile')?>
193        <?php tpl_button('login')?>
194        <?php tpl_button('index')?>
195        <?php tpl_button('top')?>&nbsp;
196      </div>
197      <div class="clearer"></div>
198    </div>  <!-- end bar__bottom-->
199
200  </div>  <!-- end stylefoot-->
201
202</div>  <!-- end main_page -->
203
204<div id="footer">
205<?php /*old includehook*/ @include(dirname(__FILE__).'/footer.html') ?>
206</div>
207
208
209<div class="no"><?php /* provide DokuWiki housekeeping, required in all templates */ tpl_indexerWebBug()?></div>
210
211</div>  <!-- wrapper -->
212<!--  WRAPPER END -->
213</body>
214</html>
215