多站点3。4.1 wordpress
我用htaccess规则重定向了wp admin,并通过wp config重命名了wp内容和插件http://codex.wordpress.org/Editing_wp-config.php#Moving_wp-content现在我不能再上传图片了。
当我尝试上载图像时,它会开始处理,但随后出现http错误,或者说您确定要这样做,但不允许我上载图像。
this is in .htacess
RewriteEngine On
RewriteBase /
RewriteRule ^login$ wp-login.php
RewriteRule ^index\\.php$ - [L]
# uploaded files
RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteRule ^([_0-9a-zA-Z-]+/)?private-admin/?$ $1private-admin/index.php?wdeb_on [R=301,L]
RewriteRule ^private-admin(.*)$ wp-admin$1
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin/([_0-9a-zA-Z-]+).php\\?(.*)$ $1private-admin/$2\\.php\\?$3 [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^[_0-9a-zA-Z-]+/(wp-(content|admin|includes).*) $1 [L]
RewriteRule ^[_0-9a-zA-Z-]+/(.*\\.php)$ $1 [L]
RewriteRule . index.php [L]
This is in wp-config /* 将wp admin重定向到专用管理文件夹的更改*/
$redirect_url=$_SERVER[\'REQUEST_URI\'];
if(preg_match(\'/wp-admin/i\', $redirect_url)) header(\'Location: \'.str_replace(\'wp-admin\', \'private-admin\', $redirect_url));
/** Change name of wp-config and plugins */
define( \'WP_CONTENT_DIR\', $_SERVER[\'DOCUMENT_ROOT\'] . \'/private-content\' );
define( \'WP_CONTENT_URL\', \'http://mysite.com/private-content\');
define( \'WP_PLUGIN_DIR\', $_SERVER[\'DOCUMENT_ROOT\'] . \'/private-content/resources\' );
define( \'WP_PLUGIN_URL\', \'http://mysite.com/private-content/resources\');
define( \'PLUGINDIR\', $_SERVER[\'DOCUMENT_ROOT\'] . \'/private-content/resources\' );
这是“网络>设置>站点>/>图像上载路径:私有内容/上载”中的图像url路径
关于如何修复此问题的建议?谢谢