modify_database function change - if no ; in single line sql strings, add it

This commit is contained in:
mjollnir_
2004-11-22 04:10:05 +00:00
parent e3da2769b8
commit 1e47ecd5d9
+4
View File
@@ -88,6 +88,10 @@ function modify_database($sqlfile="", $sqlstring="") {
$lines = file($sqlfile);
}
} else {
$sqlstring = trim($sqlstring);
if ($sqlstring{strlen($sqlstring)-1} != ";") {
$sqlstring .= ";"; // add it in if it's not there.
}
$lines[] = $sqlstring;
}