正在将 www 添加到我的网站

发布于 2024-10-07 23:17:45 字数 333 浏览 1 评论 0原文

我不知道为什么,但如果我输入 http://mysite.com/subsite 它会将我重定向到 http://www.mysite.com/subsite,htaccess 文件只是标准的 wordpress htaccess 文件,如果我尝试修改它以从网址中删除 www,它会引发重定向错误(因为它直接删除了 www,但随后又添加了 www,将其陷入无限循环)。有谁知道我的网址可能会发生什么?

谢谢!

I don't know why but if I type http://mysite.com/subsite it redirects me to http://www.mysite.com/subsite, the htaccess file is just the standard wordpress htaccess file, if I try to modify it to remove the www from the url it throws me a redirection error (since it removes the www corectly but then something adds the www again trapping it in an infinite loop). Does anyone know what could be doing this to my url?

Thanks!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

往日 2024-10-14 23:17:45

打开管理仪表板并转到“设置”->“常规”,然后查找“WordPress 地址 (URL)”或“站点地址 (URL)”。无论您将其中一项设置为什么,都会进行 URL 重写。不过我忘了是哪一个了。

Open the admin dashboard and goto Settings->General and then look for either "WordPress address (URL)" or "Site address (URL)". Whatever you have one of these set to is what is doing the URL rewriting. I forgot which one though.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文