diff --git a/bureau/admin/adm_doadd.php b/bureau/admin/adm_doadd.php index e9a45967..83d7acce 100644 --- a/bureau/admin/adm_doadd.php +++ b/bureau/admin/adm_doadd.php @@ -68,7 +68,7 @@ if (!($u=$admin->add_mem($login, $pass, $nom, $prenom, $nmail, $canpass, $type, $ftp->add_ftp($login,"",$pass,"/"); $mem->unsu(); - $error=_("The new member has been successfully created"); + $error=_("The new member has been successfully created"); include("adm_list.php"); exit; diff --git a/bureau/admin/sql_del.php b/bureau/admin/sql_del.php index 284823cd..f99bfbbf 100644 --- a/bureau/admin/sql_del.php +++ b/bureau/admin/sql_del.php @@ -35,7 +35,7 @@ if ($confirm=="y") { while (list($key,$val)=each($_POST)) { if (substr($key,0,4)=="del_") { // Effacement de la base $val - $r=$mysql->del_db($val); + $r=$mysql->del_db(substr($key,4)); if (!$r) { $error.=$err->errstr()."
"; } else { @@ -48,7 +48,7 @@ if ($confirm=="y") { } $found=false; -foreach($_POST as $k) { +foreach($_POST as $key=>$val) { if (substr($key,0,4)=="del_") { $found=true; } diff --git a/bureau/admin/sql_list.php b/bureau/admin/sql_list.php index 87865a6b..544c493f 100644 --- a/bureau/admin/sql_list.php +++ b/bureau/admin/sql_list.php @@ -58,7 +58,7 @@ for($i=0;$i - " name="del_" value="" /> + " name="del_" value="" />
">
">
diff --git a/bureau/class/m_mysql.php b/bureau/class/m_mysql.php index 3f340726..cecec4bc 100644 --- a/bureau/class/m_mysql.php +++ b/bureau/class/m_mysql.php @@ -329,7 +329,7 @@ class m_mysql { // OK, creation now... $db->query("INSERT INTO db (uid,login,pass,db) VALUES ('$cuid','".$login."','$password','".$dbname."');"); // give everything but GRANT on $user.* - $db->query("GRANT ALL PRIVILEGES ON `".$dbname."`.* TO '".$login."'@'$this->client' IDENTIFIED BY '".$password."'"); + $db->query("GRANT ALL PRIVILEGES ON `".$dbname."`.* TO '".$login."'@'$this->client' IDENTIFIED BY '".addslashes($password)."'"); $db->query("CREATE DATABASE `".$dbname."`;"); return true; }