我正在使用wordpress多站点承诺。该网站可以使用http从LAN访问,但不能使用https访问。
我现在的目标是将网站发布到互联网上。我有反向代理和DNS服务器,但我非常确定,问题不是来自他们。
以下是错误:
Access forbidden!
You don't have permission to access the requested directory. There is either no index document or the directory is read-protected.
If you think this is a server error, please contact the webmaster.
Error 403
ddmc.co.id
Apache/2.4.39 (Win64) OpenSSL/1.1.1b PHP/7.3.4
以下是当前配置:
WP_2_OPTION
siteurl: http://ddmc.co.id/id
home: http://ddmc.co.id/id
WP_SITE
domain: ddmc.co.id
path: /
WP_SITEMETA
siteurl: http://ddmc.co.id
WP_BLOGS
domain: ddmc.co.id path:/
domain: ddmc.co.id path:/id/
WP_OPTION
domain: http://ddmc.co.id path:/
domain: http://ddmc.co.id path:/id/
WP-配置.php
define('WP_ALLOW_MULTISITE', true);
define('MULTISITE', true);
define('SUBDOMAIN_INSTALL', true);
define('DOMAIN_CURRENT_SITE', 'ddmc.co.id');
define('PATH_CURRENT_SITE','/');
define('SITE_ID_CURRENT_SITE', 1);
define('BLOG_ID_CURRENT', 1);
define('WP_MEMORY_LIMIT', '512M');
htaccess
# BEGIN WordPress
RewriteEngine On
RewriteBase /
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]
# END WordPress
HTPD-vhosts
<Directory "c:/xampp/htdocs/ddmc">
Options Indexes FollowSymLinks MultiViews
AllowOverride all
Order Deny,Allow
Allow from all
Require all granted
</Directory>
我已经对此进行了一周的故障排除,但没有成功,请帮忙。
<Directory "c:/xampp/htdocs/hcml">
这是错别字hcml
吗?基本上,您的路由以某种方式错误,或者您的文件权限由Apache
用户读取WordPress
文件夹。
我刚刚发现了问题。
问题是在我将 httpd.conf 下的目录从 htdocs 更改为我的网站文件夹之后。
<Directory "C:/xampp/htdocs/">
更改为:
<Directory "C:/xampp/htdocs/ddmc">
现在的问题是,您的网站重定向到仪表板。如何在没有错误禁止访问的情况下更改文档根目录?