在安装新插件时候
会出现输入主机、ftp用户名以及密码的对话框
基本上怎么输都是提示无法连接到localhost:21端口
修改了文件夹权限以及在wp-config.php的最末端加入了
//其定义值可以为:'direct', 'ssh', 'ftpext' (ftp方式)or'ftpsockets'(Socket extension)
define('FS_METHOD', 'direct');
//修改目录权限默认是0755
define('FS_CHMOD_DIR', '0755');
之后再次安装插件 提示:
Unpacking the package…
Installing the plugin…
Warning: array_keys() expects parameter 1 to be array, boolean given in /Applications/XAMPP/xamppfiles/htdocs/wordpress/wp-admin/includes/class-wp-upgrader.php on line 189
Incompatible Archive.
Plugin install failed.
寻求解决方法
189 $source_files = array_keys( $wp_filesystem->dirlist($remote_source) );