aboutsummaryrefslogtreecommitdiffhomepage
path: root/install
diff options
context:
space:
mode:
Diffstat (limited to 'install')
-rwxr-xr-xinstall/index.php12
1 files changed, 8 insertions, 4 deletions
diff --git a/install/index.php b/install/index.php
index bb351095..ea5d7d47 100755
--- a/install/index.php
+++ b/install/index.php
@@ -94,10 +94,14 @@ else if (isset($_POST['install'])) {
94 $errors[] = 'Impossible to create the SQLite database file. Please check your file permissions.'; 94 $errors[] = 'Impossible to create the SQLite database file. Please check your file permissions.';
95 } 95 }
96 else { 96 else {
97 $db_path = 'sqlite:' . realpath('') . '/db/poche.sqlite'; 97 try {
98 $handle = new PDO($db_path); 98 $db_path = 'sqlite:' . realpath('') . '/db/poche.sqlite';
99 $handle->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); 99 $handle = new PDO($db_path);
100 $sql_structure = ""; 100 $handle->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
101 $sql_structure = "";
102 } catch (PDOException $e) {
103 $errors[] = "SQLite has encountered an issue : " . $e->getMessage();
104 }
101 } 105 }
102 } else { 106 } else {
103 // MySQL and Postgre 107 // MySQL and Postgre