0

I have a website. It has a error page with the name 404.php. I set the headers in the 404.php using:

header("HTTP/2 404 Not Found");

When I open console in Google Chrome in the error page now it says:

Failed to load resource: the server responded with a status of 404 ()

Before, it displayed the normal:

Failed to load resource: the server responded with a status of 404 (Not Found)

The word "Not Found" is not displaying in the console tab. So because of this users would think that it is a fake 404 response even if it is real.

Please help me with this.

It works, but it doesn't display "Not Found" in the console and in the network http headers.

Example person
  • 3,198
  • 3
  • 18
  • 45

1 Answers1

0

I am not seeing anything within the console itself relating to a 404 status code.
Console Output However, the general header record, as well as the response header record are both displaying a status code of 404.
HTTP Headers I would not worry about people seeing this as a 'false 404', as per the HTTP status code standards 404 signifies that the page is not found.

Connor
  • 16
  • 1
  • You have convinced me :) –  May 11 '19 at 12:14
  • I now learnt that this happens only on HTTP/2, but not HTTP/1.1. And also, I am the person who posted this, but deleted my account before and recreated it, so I can't access it. I would request the moderators to delete this, or maybe somehow give me access to this question by making it so I own it. I have proof, because the website domain is mentioned here. And I still own it. – Example person Feb 01 '20 at 18:34