summaryrefslogtreecommitdiff
path: root/include/db.php
diff options
context:
space:
mode:
Diffstat (limited to 'include/db.php')
-rw-r--r--include/db.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/db.php b/include/db.php
index 1401c089b..7b2bd2a77 100644
--- a/include/db.php
+++ b/include/db.php
@@ -22,7 +22,7 @@ function db_connect($host, $user, $pass, $db) {
$link = pg_connect($string);
if (!$link) {
- die("Connection failed: " . pg_last_error($link));
+ die("Unable to connect to database (as $user to $host, database $db):" . pg_last_error());
}
return $link;
@@ -36,7 +36,7 @@ function db_connect($host, $user, $pass, $db) {
}
return $link;
} else {
- die("Connection failed: " . mysql_error($link));
+ die("Unable to connect to database (as $user to $host, database $db): " . mysql_error());
}
}
}