最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

redirect - Loading wp-contentuploadssite as site

programmeradmin2浏览0评论

I love websites so much that I want to put a website into another website. I have a static site under /wp-content/uploads/site. It has a lot of pages and I can access it without an issue in https://[my-domain]/wp-content/uploads/site but I want it accessible as a root directory: https://[my-domain]/site

I tried adding the following rule to my .htaccess:

RewriteRule ^site/(.*)$ /wp-content/uploads/site/$1 [L]

This works because I can load the static site as https://[my-domain]/site but when I click on links (absolute URLs such as /site/url I get redirected to https://[my-domain]/wp-content/uploads/site/url

BTW: I added my rule right before RewriteRule ^index\.php$ - [L]

Any ideas on what's not working?

发布评论

评论列表(0)

  1. 暂无评论