我搜索的内容超出了您的想象,但是找不到有用的东西。因此,我在问这个问题。
我想在Laravel的公共目录中安装WordPress。我有这些配置:
/public/.htaccess
<IfModule mod_rewrite.c>
RewriteEngine On
#RewriteCond %{REQUEST_URI} !^/blog/
#RewriteCond $1 !^(blog)
# Force http to https
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php [QSA,L]
</IfModule>
/public/blog/.htaccess
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
/etc/httpd/conf/httpd.conf
DocumentRoot /home/mysite/public_html/public
ProxyPassMatch "^/blog" "unix:/run/php-fpm/www.sock|fcgi://localhost:9000/public/blog"
ProxyPassMatch "^/(.*\.php)$" "unix:/run/php-fpm/www.sock|fcgi://localhost:9000/public/index.php"
问题是mysite.com
正常工作,但是mysite.com/blog
再次将我重定向到mysite.com
,并且mysite.com/blog/index
返回此页面,但找不到该样式适用于WordPress。
请帮助我解决此问题。