diff options
Diffstat (limited to 'index.php')
-rw-r--r-- | index.php | 18 |
1 files changed, 10 insertions, 8 deletions
@@ -10,17 +10,19 @@ | |||
10 | 10 | ||
11 | include dirname(__FILE__).'/inc/config.php'; | 11 | include dirname(__FILE__).'/inc/config.php'; |
12 | 12 | ||
13 | $entries = display_view($view); | 13 | $entries = get_entries($view); |
14 | 14 | ||
15 | $tpl->assign('title', 'poche, a read it later open source system'); | 15 | $tpl->assign('title', 'poche, a read it later open source system'); |
16 | $tpl->assign('view', $view); | ||
17 | $tpl->assign('poche_url', get_poche_url()); | ||
18 | $tpl->assign('entries', $entries); | 16 | $tpl->assign('entries', $entries); |
19 | $tpl->assign('load_all_js', 1); | 17 | $tpl->assign('load_all_js', 1); |
20 | $tpl->assign('token', $_SESSION['token_poche']); | ||
21 | 18 | ||
22 | $tpl->draw('head'); | 19 | $tpl->draw('head'); |
23 | $tpl->draw('home'); | 20 | if (Session::isLogged()) { |
24 | $tpl->draw('entries'); | 21 | $tpl->draw('home'); |
25 | $tpl->draw('js'); | 22 | $tpl->draw('entries'); |
26 | $tpl->draw('footer'); | 23 | $tpl->draw('js'); |
24 | } | ||
25 | else { | ||
26 | $tpl->draw('login'); | ||
27 | } | ||
28 | $tpl->draw('footer'); \ No newline at end of file | ||