我的config.ini.php3 文件
<?php
/* $Id: config.inc.php3,v 1.28 2000/07/13 13:52:48 tobias Exp $ *//*
 *  phpMyAdmin Configuration File
 *  All directives are explained in Documentation.html
 */// The $cfgServers array starts with $cfgServers[1].  Do not use $cfgServers[0].
// You can disable a server config entry by setting host to ''.
$cfgServers[1]['host'] = 'localhost';           // MySQL hostname
$cfgServers[1]['port'] = '';                    // MySQL port - leave blank for default port
$cfgServers[1]['adv_auth'] = false;             // Use advanced authentication?
$cfgServers[1]['stduser'] = 'root';             // MySQL standard user (only needed with advanced auth)
$cfgServers[1]['stdpass'] = '';                 // MySQL standard password (only needed with advanced auth)
$cfgServers[1]['user'] = 'root';                // MySQL user (only needed with basic auth)  用戶名
$cfgServers[1]['password'] = '*******';                // MySQL password (only needed with basic auth)     ****** 換成你的密碼
$cfgServers[1]['only_db'] = '';                 // If set to a db-name, only this db is accessible
$cfgServers[1]['verbose'] = '';                 // Verbose name for this host - leave blank to show the hostname$cfgServers[2]['host'] = '';
$cfgServers[2]['port'] = '';
$cfgServers[2]['adv_auth'] = false;
$cfgServers[2]['stduser'] = '';
$cfgServers[2]['stdpass'] = '';
$cfgServers[2]['user'] = '';
$cfgServers[2]['password'] = '';
$cfgServers[2]['only_db'] = '';
$cfgServers[2]['verbose'] = '';$cfgServers[3]['host'] = '';
$cfgServers[3]['port'] = '';
$cfgServers[3]['adv_auth'] = false;
$cfgServers[3]['stduser'] = '';
$cfgServers[3]['stdpass'] = '';
$cfgServers[3]['user'] = 'root';
$cfgServers[3]['password'] = '';
$cfgServers[3]['only_db'] = '';
$cfgServers[3]['verbose'] = '';// If you have more than one server configured, you can set $cfgServerDefault
// to any one of them to autoconnect to that server when phpMyAdmin is started,
// or set it to 0 to be given a list of servers without logging in
// If you have only one server configured, $cfgServerDefault *MUST* be
// set to that server.
$cfgServerDefault = 1;                            // Default server  (0 = no default server)
$cfgServer = '';
unset($cfgServers[0]);$cfgManualBase = "http://www.mysql.com/documentation/mysql/bychapter/";$cfgConfirm = true;
$cfgPersistentConnections = false;$cfgBorder      = "0";
$cfgThBgcolor  = "#D3DCE3";
$cfgBgcolorOne = "#CCCCCC";
$cfgBgcolorTwo = "#DDDDDD";
$cfgMaxRows = 30;
$cfgMaxInputsize = "300px";
$cfgOrder = "ASC";
$cfgShowBlob = true;
$cfgShowSQL = true;//require("english.inc.php3");   //使用英文界面
//require("chinese_gb.inc.php3"); //使用中文簡体界面
require("chinese_big5.inc.php3"); //使用中文繁体界面
$cfgColumnTypes = array(
   "TINYINT",
   "SMALLINT",
   "MEDIUMINT",
   "INT",
   "BIGINT",
   "FLOAT",
   "DOUBLE",
   "DECIMAL",
   "DATE",
   "DATETIME",
   "TIMESTAMP",
   "TIME",
   "YEAR",
   "CHAR",
   "VARCHAR",
   "TINYBLOB",
   "TINYTEXT",
   "TEXT",
   "BLOB",
   "MEDIUMBLOB",
   "MEDIUMTEXT",
   "LONGBLOB",
   "LONGTEXT",
   "ENUM",
   "SET");$cfgFunctions = array(
   "ASCII",
   "CHAR",
   "SOUNDEX",
   "CURDATE",
   "CURTIME",
   "FROM_DAYS",
   "FROM_UNIXTIME",
   "NOW",
   "PASSWORD",
   "PERIOD_ADD",
   "PERIOD_DIFF",
   "TO_DAYS",
   "USER",
   "WEEKDAY",
   "RAND");$cfgAttributeTypes = array(
   "",
   "BINARY",
   "UNSIGNED",
   "UNSIGNED ZEROFILL");// Setting magic_quotes_runtime - do not change!
set_magic_quotes_runtime(0);
?>

解决方案 »

  1.   

    楼上的朋友,你的代码登录后能看到所有数据库,我的意思是一个用户只能管理自己的数据库呀,那个$cfgServers[1]['adv_auth'] = false;要设置成这样哦。
      

  2.   

    换最版的phpMyadmin吧, 然后用HTTP验证管理, 就不需要在config.inc.php中设置了. 设置这个:
    $cfg['Servers'][$i]['auth_type']     = 'http';    // Authentication method (config, http or cookie based)?
      

  3.   

    http://gr-studio.com/mysql/
    就像这样一个网站上实现的功能!
    急,谢谢
      

  4.   

    http验证是不是需要apache安装才能通过,我用的是iis
      

  5.   

    http://gr-studio.com/mysql/
    我也配不出这种登陆,我改成http验证方式后,要用windows用户登陆,而不是数据库用户,这是怎么回事?
      

  6.   

    我配出來了,我用的是phpmyadmin2.2.6
    改如下配置$cfgServers[$i]['auth_type']     = 'cookie';    // Authentication method (config, http or cookie based)?
    $cfgServers[$i]['user']          = 'root';      // MySQL user
    $cfgServers[$i]['password']      = '';  // MySQL password (only needed$cfgPmaAbsoluteUri = 'http://localhost/phpmyadmin/';  //你的phpmyadmin所在的目錄