首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >停止https和ServerName重定向apache2

停止https和ServerName重定向apache2
EN

Stack Overflow用户
提问于 2021-06-25 07:27:50
回答 1查看 40关注 0票数 0

我的问题很简单,我想访问http://tunisie-telegraph.com,但它将我重定向到https://tunisietelegraph.com

我的域名是ns1.digitalocean.com,ns2.digitalocean.com,ns3.digitalocean.com我有2个"A“和2个"AAAA”记录(有www和没有www)

我已经删除了.htaccess文件

我的虚拟主机文件:

代码语言:javascript
复制
# Added to mitigate CVE-2017-8295 vulnerability
UseCanonicalName On

<VirtualHost *:80>
        ServerAdmin private@gmail.com

        ServerName tunisie-telegraph.com
        ServerAlias www.tunisie-telegraph.com

        DocumentRoot /var/www/html

        <Directory /var/www/html/>
            Options FollowSymLinks
            AllowOverride All
            Require all granted
        </Directory>

        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2021-06-25 14:35:08

您可以检查网站网址和主页网址在wp_options表中。可能是其中一列中的URL不同,因为当我像这样添加url时,它不会重定向

或者您也可以从wp_config.php设置站点网址和主页网址

代码语言:javascript
复制
define( 'WP_HOME', 'http://tunisie-telegraph.com' );
define( 'WP_SITEURL', 'http://tunisie-telegraph.com' );
票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/68123746

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档