summaryrefslogtreecommitdiff
path: root/app/views/index/index.phtml
blob: 73e5fcc4dfa39f70ea42e3d37ad47b61295cd092 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?php

$output = Request::param ('output', 'normal');
$token = $this->conf->token();
$token_param = Request::param ('token', '');
$token_is_ok = ($token != '' && $token == $token_param);

if(!login_is_conf ($this->conf) ||
   is_logged() ||
   $this->conf->anonAccess() == 'yes' ||
   ($output == 'rss' && $token_is_ok)) {
	if($output == 'rss') {
		$this->renderHelper ('view/rss_view');
	} elseif($output == 'reader') {
		$this->renderHelper ('view/reader_view');
	} elseif($output == 'global') {
		$this->renderHelper ('view/global_view');
	} else {
		$this->renderHelper ('view/normal_view');
	}
} else {
?>
<div class="post content">
	<h1><?php echo Translate::t ('forbidden_access'); ?></h1>
	<p><?php echo Translate::t ('forbidden_access_description'); ?></p>
</div>
<?php
}