From 9d3b88b3796496b68e762d50904a7ab609edc9c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20L=C5=93uillet?= Date: Mon, 7 Oct 2013 13:12:28 +0200 Subject: bug fix #266: make installation steps easier --- index.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'index.php') diff --git a/index.php b/index.php index 4aebfe10..f1953c2c 100644 --- a/index.php +++ b/index.php @@ -35,7 +35,12 @@ $tpl_vars = array( if (! empty($notInstalledMessage)) { if (! Poche::$canRenderTemplates || ! Poche::$configFileAvailable) { # We cannot use Twig to display the error message - die($notInstalledMessage); + echo '

Errors

    '; + foreach ($notInstalledMessage as $message) { + echo '
  1. ' . $message . '
  2. '; + } + echo '
'; + die(); } else { # Twig is installed, put the error message in the template $tpl_file = Tools::getTplFile('error'); -- cgit v1.2.3 From 031df528b611a5c6639c0d86636633da098d8aa2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20L=C5=93uillet?= Date: Mon, 7 Oct 2013 13:19:34 +0200 Subject: bug fix #268: move POCHE_VERSION in index.php and change the name to avoid conflicts when updating --- index.php | 1 + 1 file changed, 1 insertion(+) (limited to 'index.php') diff --git a/index.php b/index.php index f1953c2c..22696c6f 100644 --- a/index.php +++ b/index.php @@ -8,6 +8,7 @@ * @license http://www.wtfpl.net/ see COPYING file */ +define ('POCHE', '1.0.0'); require_once 'inc/poche/global.inc.php'; # Start Poche -- cgit v1.2.3 From 5011388f39432f810e397a60d9b200faba6c868b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20L=C5=93uillet?= Date: Mon, 7 Oct 2013 14:26:25 +0200 Subject: bug fix #215: change language from config screen --- index.php | 3 +++ 1 file changed, 3 insertions(+) (limited to 'index.php') diff --git a/index.php b/index.php index 22696c6f..a6459270 100644 --- a/index.php +++ b/index.php @@ -67,7 +67,10 @@ if (isset($_GET['login'])) { $poche->export(); } elseif (isset($_GET['updatetheme'])) { $poche->updateTheme(); +} elseif (isset($_GET['updatelanguage'])) { + $poche->updateLanguage(); } + elseif (isset($_GET['plainurl']) && !empty($_GET['plainurl'])) { $plain_url = new Url(base64_encode($_GET['plainurl'])); $poche->action('add', $plain_url); -- cgit v1.2.3 From 36b92198425618a098941494000e21935208cb90 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20L=C5=93uillet?= Date: Thu, 17 Oct 2013 17:03:55 +0200 Subject: bug fix #251: login failure --- index.php | 1 + 1 file changed, 1 insertion(+) (limited to 'index.php') diff --git a/index.php b/index.php index a6459270..fdcfc328 100644 --- a/index.php +++ b/index.php @@ -10,6 +10,7 @@ define ('POCHE', '1.0.0'); require_once 'inc/poche/global.inc.php'; +session_start(); # Start Poche $poche = new Poche(); -- cgit v1.2.3 From df6afaf0909506a334ef2b8c6f69770cd9890e0d Mon Sep 17 00:00:00 2001 From: Denis Sacchet Date: Sun, 20 Oct 2013 16:53:54 +0200 Subject: Added support for http_auth --- index.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'index.php') diff --git a/index.php b/index.php index fdcfc328..d79f3f95 100644 --- a/index.php +++ b/index.php @@ -81,6 +81,8 @@ if (Session::isLogged()) { $poche->action($action, $url, $id); $tpl_file = Tools::getTplFile($view); $tpl_vars = array_merge($tpl_vars, $poche->displayView($view, $id)); +} elseif(isset($_SERVER['PHP_AUTH_USER'])) { + $poche->login($referer); } else { $tpl_file = Tools::getTplFile('login'); } @@ -90,4 +92,4 @@ $messages = $poche->messages->display('all', FALSE); $tpl_vars = array_merge($tpl_vars, array('messages' => $messages)); # display poche -echo $poche->tpl->render($tpl_file, $tpl_vars); \ No newline at end of file +echo $poche->tpl->render($tpl_file, $tpl_vars); -- cgit v1.2.3 From 027b4e156853b4d5e358e19e83506ec4446de7ab Mon Sep 17 00:00:00 2001 From: Denis Sacchet Date: Sun, 20 Oct 2013 23:28:45 +0200 Subject: Adding support for http_auth --- index.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'index.php') diff --git a/index.php b/index.php index d79f3f95..d400354d 100644 --- a/index.php +++ b/index.php @@ -82,9 +82,17 @@ if (Session::isLogged()) { $tpl_file = Tools::getTplFile($view); $tpl_vars = array_merge($tpl_vars, $poche->displayView($view, $id)); } elseif(isset($_SERVER['PHP_AUTH_USER'])) { - $poche->login($referer); + if($poche->store->userExists($_SERVER['PHP_AUTH_USER'])) { + $poche->login($referer); + } else { + $poche->messages->add('e', _('login failed: user doesn\'t exist')); + Tools::logm('user doesn\'t exist'); + $tpl_file = Tools::getTplFile('login'); + $tpl_vars['http_auth'] = 1; + } } else { $tpl_file = Tools::getTplFile('login'); + $tpl_vars['http_auth'] = 0; } # because messages can be added in $poche->action(), we have to add this entry now (we can add it before) -- cgit v1.2.3 From 6ae804853f6f2e10d394b6abfb977b7a251ee7e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20L=C5=93uillet?= Date: Fri, 25 Oct 2013 08:45:28 +0200 Subject: on the road to 1.1.0 --- index.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'index.php') diff --git a/index.php b/index.php index d400354d..66a2e816 100644 --- a/index.php +++ b/index.php @@ -8,7 +8,7 @@ * @license http://www.wtfpl.net/ see COPYING file */ -define ('POCHE', '1.0.0'); +define ('POCHE', '1.1.0'); require_once 'inc/poche/global.inc.php'; session_start(); -- cgit v1.2.3