那么,是否不格式化代码
Although my answer doesn\'t solve your permission issue, but it may help when you retry to rebuild the site after several failures.
一旦我将我的在线wordpress复制到本地,为了让它工作,我只需遵循以下步骤-
复制了所有文件和文件夹
复制数据库并添加到本地数据库
编辑wp配置。php文件以及数据库凭据(希望对您有用)-
//require\\u once(ABSPATH。\'wp settings.php\')之前的部分wp配置文件;
$content\\u directory=“目录”/“内容”$plugins\\u目录=“plugins\\u directory”/“代码”;;
$currenthost=“当前主机”;http://quot$_服务器[\'HTTP\\U主机\']$currentpath=preg\\u replace(“@/+$@”,“”,目录名($\\u SERVER[\'SCRIPT\\u NAME]))$currentpath=preg\\u replace(“//wp.+/”,“”,$currentpath);定义(\'WP\\U HOME\',$当前主机。$当前路径);定义(\'WP\\U SITEURL\',$currenthost。$currentpath);
定义(\'WP\\u CONTENT\\u URL\',$currenthost。$currentpath。$CONTENT\\u directory);定义(\'WP\\u CONTENT\\u DIR\',目录名(FILE ) . $content\\u目录);
定义(\'DOMAIN\\u CURRENT\\u SITE\',$currenthost.$currentpath);
定义(\'WP\\u PLUGIN\\u DIR\',WP\\u CONTENT\\u DIR.$plugins\\u directory);定义(\'WP\\u PLUGIN\\u URL\',WP\\u CONTENT\\u URL.$plugins\\u directory);定义(\'WPMU\\u PLUGIN\\u DIR\',WP\\u CONTENT\\u DIR.";/multicode";);定义(\'WPMU\\u PLUGIN\\u URL\',WP\\u CONTENT\\u URL.“multicode”);
定义(\'UPLOADS\',WP\\u CONTENT\\u DIR./文件\');
定义(\'WP\\U POST\\U REVISIONS\',2);define(\'WP\\u DEBUG\\u DISPLAY\',false);
@定义(\'ADMIN\\u COOKIE\\u PATH\',\'./\');
/*手动代码在此结束*/
或者您可以手动指定$currenthost
和$currentpath
特定于您的安装。我在本地也能得到同样的结果。