Php 要将我的HTML页面重定向到网站主页吗

Php 要将我的HTML页面重定向到网站主页吗,php,html,css,themes,custom-wordpress-pages,Php,Html,Css,Themes,Custom Wordpress Pages,我已经为我的wordpress网站主页创建了一个HTML页面,现在我想将该HTML页面重定向到我的网站主页。 如果您计划从new.html页面重定向到wordpressindex.php文件,则该页面已上载到我的wordpress文件夹根目录: 使用PHP重定向: header('Location: http://www.example.com/'); 使用HTML元重定向: <meta http-equiv = "refresh" content = "2

我已经为我的wordpress网站主页创建了一个HTML页面,现在我想将该HTML页面重定向到我的网站主页。
如果您计划从
new.html
页面重定向到
wordpress
index.php
文件,则该页面已上载到我的wordpress文件夹根目录:

使用
PHP
重定向:

header('Location: http://www.example.com/');
使用
HTML元重定向

<meta http-equiv = "refresh" content = "2; url = https://www.example.com" />

只需使用meta refresh属性重定向到其他站点

(content=“0;将立即执行重定向。)


将下面的代码添加到您的html页面元标记,以重定向到您的网站

    <head>
       <meta http-equiv = "refresh" content = "1; url = https://www.yoursite.com" />
</head>


或者如果无法重定向,请向我建议另一种方式谢谢您迄今为止做了哪些尝试?您遇到了什么困难?这与CSS或主题概念有何关系?
<meta http-equiv="refresh" content="0;url=http://example.com/" />
    <head>
       <meta http-equiv = "refresh" content = "1; url = https://www.yoursite.com" />
</head>