summaryrefslogtreecommitdiff
path: root/installer/web.php
diff options
context:
space:
mode:
authorNathan Kinkade <nath@nkinka.de>2012-06-01 15:10:46 +0000
committerNathan Kinkade <nath@nkinka.de>2012-06-01 15:10:46 +0000
commitb52e834bd0bab530e98537d52b31d4b37f199739 (patch)
treeff31dd4f6c2afaeae380f10dc691cde3cb4e6739 /installer/web.php
parentf5098f54b8279f468d94747b1156e15ea05d6d25 (diff)
parent4c98b218316df00c8bf3eeb28a8324ec64348bff (diff)
Merge branch 'master' of git://github.com/gallery/gallery3
Diffstat (limited to 'installer/web.php')
-rw-r--r--installer/web.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/installer/web.php b/installer/web.php
index 6102f0e0..12f42d02 100644
--- a/installer/web.php
+++ b/installer/web.php
@@ -39,6 +39,13 @@ if (installer::already_installed()) {
"prefix" => $_POST["prefix"],
"type" => function_exists("mysqli_set_charset") ? "mysqli" : "mysql");
list ($config["host"], $config["port"]) = explode(":", $config["host"] . ":");
+ foreach ($config as $k => $v) {
+ if ($k == "password") {
+ $config[$k] = str_replace("'", "\\'", $v);
+ } else {
+ $config[$k] = strtr($v, "'`", "__");
+ }
+ }
if (!installer::connect($config)) {
$content = render("invalid_db_info.html.php");