为本地托管的WordPress网站安装插件需要ftp详细信息 [英] Installing plugin for wordpress website hosted locally is asking for ftp details

查看:335
本文介绍了为本地托管的WordPress网站安装插件需要ftp详细信息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在进行本地托管的wordpress安装。



当我在windows上时,wordpress安装就没有问题。



但是每当我转移到Ubuntu时,我的插件安装会询问主机名,ftp用户名和密码。

早些时候我也发生过几次。以前我经历了一些线程,并得到了一个解决方案,使用localhost作为主机名,并使用我的操作系统用户名和密码来获取ftp详细信息。这对我来说很有效。



但现在它不适合我。



有时更改文件许可也起作用。但是,在我目前的情况下,它不起作用。

因此,如果我知道这是为什么的根本原因,而不是尝试随机结果,我认为它会更好发生,然后正确的解决方案来解决它。



所以,如果任何人可以帮助我在这里。谢谢。

解决方案

打开wp-config.php文件并添加这段代码:

  / **设置FTP详细信息** / 
define('FS_METHOD','direct') ;


I am working on locally hosted wordpress installation.

When I am on windows the wordpress installation is all fine.

But whenever I move to ubuntu then my plugin installation asks for host name, ftp username and password.

It happened several times for me earlier too. Previously I went through some thread and got a solution to use localhost as host name and use my operating system username and password for ftp details. Which worked for me then.

But now it is not working for me.

And sometimes changing the file permission worked too. But again in my current case it is not working.

So, instead of trying random results, I think it will be better if I know the root cause of why this is happening and then the correct solution to troubleshoot it.

So, if any one can help me here. Thanks.

解决方案

open wp-config.php file and add this code :

/** Setup FTP Details **/ 
define('FS_METHOD', 'direct');

这篇关于为本地托管的WordPress网站安装插件需要ftp详细信息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆