我有一个多站点(子目录)网络,大约有10个站点,在当前环境中运行了几个月,没有任何问题。突然(没有任何代码更改)我在尝试访问每个子网站的wp admin时出现404个错误(所有网站的前端和主站点的wp admin工作正常)。
例如:
subsite1/wp admin-页面加载,但所有资源都抛出404。在控制台中获取错误,如:
Refused to apply style from \'.../wp-admin/load-styles.php...&ver=4.9.8\' because its MIME type (\'text/html\') is not a supported stylesheet MIME type, and strict MIME checking is enabled.
load-scripts.php:1
Failed to load resource: the server responded with a status of 404 ()
如果我尝试访问wp admin中的页面,如:
subsite1/wp-admin/anything.php
, 页面抛出404。
这是我的htaccess文件:
RewriteEngine On
RewriteBase /
RewriteCond %{HTTPS} off
RewriteRule ^index\\.php$ - [L]
# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\\.php)$ $2 [L]
RewriteRule . index.php [L]
有什么想法吗?谢谢