设置phpmyadmin登录时可以指定数据库服务器

安装好phpmyadmin 后打开,默认 只有用户名和密码两个输入框,因为默认的服务器是 localhost,我们需要连接到非本地的mysql时就没地方输入服务器的域名或者ip。
将 配置文件中的 AllowArbitraryServer 由 false 修改为 true;
修改 phpmyadmin根目录/config.inc.php
文件:
$cfg['AllowArbitraryServer'] = true; /* 允许自定义服务器,默认为false */
如果找不到config.ini.php文件,新版 phpmyadmin 配置文件路径: phpmyadmin根目录/libraries/config.default.php
$cfg['AllowArbitraryServer'] = true;
修改后刷新就显示服务器输入框了,输入域名或ip都可以,支持加端口:
版权声明:
作者:东明兄
链接:https://blog.crazyming.com/note/2362/
来源:CrazyMing
文章版权归作者所有,未经允许请勿转载。


共有 0 条评论