更新时间:2022-05-10 08:23:14
我很快就想到了:
<?
header("HTTP/1.1 404");
echo "ERROR"; // Put the contents of your 404 page here.
?>
我在 Chrome 中检查过,这将在页眉中返回 404 代码,让您可以在页面的其余部分写入任何您想要的内容.只需将 header
函数放在页面的开头即可.
I checked it in Chrome, and this will return a 404 code in the header, and let you write whatever you'd like to the rest of the page. Just put the header
function at the beginning of the page.