我试图在 localhost 的 Mac 上为 wordpress 安装 Elementor 插件,但安装失败。这些是细节:
主机名:/Applications/XAMPP/xamppfiles/htdocs/wordpress/wp-content/plugins
FTP用户名:root
密码:
使用密码,我收到此错误警报:
Failed to connect to FTP Server /Applications/XAMPP/xamppfiles/htdocs/wordpress/wp-content/plugins:21
在没有密码的情况下,我收到了此错误警报:
Unable to connect to the filesystem. Please confirm your credentials.
我搜索了类似的情况,发现必须在代码中添加这一行:
define('FS_METHOD','direct’);
然后我收到了这条消息:
Installation failed. could not create directory.
我不熟悉代码编写,而且我是 Wordpress 的新手,非常感谢您的帮助。
问候
最佳答案
试试这个命令,因为它不会将你的整个 html 暴露给黑客,这在我的情况下有效
sudo chown -R www-data:www-data /var/www/html/your-project-name
关于wordpress - 无法连接到文件系统。请确认您的凭据,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57239961/