From: Robin Appelman Date: Mon, 5 Jul 2010 13:31:59 +0000 (+0200) Subject: Do not use table perfix for sqlite X-Git-Tag: v3.0~351^2~6 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=c718716e571b66178e6397b7eb3ec169cc9a5a20;p=nextcloud-server.git Do not use table perfix for sqlite --- diff --git a/inc/lib_config.php b/inc/lib_config.php index dad2fbf8159..77fd68a189e 100755 --- a/inc/lib_config.php +++ b/inc/lib_config.php @@ -186,11 +186,13 @@ class OC_CONFIG{ //create/fill database $CONFIG_DBTYPE=$dbtype; $CONFIG_DBNAME=$_POST['dbname']; - $CONFIG_DBTABLEPREFIX=$_POST['dbtableprefix']; if($dbtype!='sqlite'){ + $CONFIG_DBTABLEPREFIX=$_POST['dbtableprefix']; $CONFIG_DBHOST=$_POST['dbhost']; $CONFIG_DBUSER=$_POST['dbuser']; $CONFIG_DBPASSWORD=$_POST['dbpassword']; + }else{ + $_POST['dbtableprefix']=''; } try{ if(isset($_POST['createdatabase']) and $CONFIG_DBTYPE!='sqlite'){ diff --git a/inc/templates/adminform.php b/inc/templates/adminform.php index 3adbd04ee73..b962ac6f31b 100755 --- a/inc/templates/adminform.php +++ b/inc/templates/adminform.php @@ -28,7 +28,7 @@ function showBackupPath(){ function dbtypechange(){ var dropdown=action=document.getElementById('dbtype'); var type=dropdown.options[dropdown.selectedIndex].value; - var inputs=Array('dbhost','dbuser','dbpass','dbpass_retype','dbcreaterow','dbAdminPwd','dbAdminUser','dbname','dbfill'); + var inputs=Array('dbhost','dbuser','dbpass','dbpass_retype','dbcreaterow','dbAdminPwd','dbAdminUser','dbname','dbfill','dbtableprefix'); var id,element; if(type=='sqlite'){ for(i in inputs){