Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7047155
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T02:44:13+00:00 2026-05-28T02:44:13+00:00

Usually, when sending a http status header from PHP, one would send the HTTP

  • 0

Usually, when sending a http status header from PHP, one would send the HTTP header like this:

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

However, the PHP manual says that for FCGI hosts, one would need to send a "Status" header that is then converted into a HTTP header by the FCGI module:

header("Status: 404 Not Found");

I am running apache 2.2 with PHP using mod_fcgi on a Windows 7 machine and sending the header using just header("HTTP/1.0 404 Not Found"); seems to work fine.

Is this something that has changed recently? Do I still need to send a Status header for FCGI hosts? Could anyone also confirm this for other platforms (solaris, linux) and other webservers (nginx, lighttp)?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T02:44:13+00:00Added an answer on May 28, 2026 at 2:44 am

    I don’t believe you need to use the ‘Status’ style header unless you have the option cgi.rfc2616_headers enabled.

    The description of that option is http://php.net/manual/en/ini.core.php

    “Tells PHP what type of headers to use when sending HTTP response
    code. If it’s set 0, PHP sends a Status: header that is supported by
    Apache and other web servers. When this option is set to 1, PHP will
    send » RFC 2616 compliant headers. Leave it set to 0 unless you know
    what you’re doing.”

    Basically you’re sending HTTP style headers to PHP and then PHP converts these to the ‘Status’ style headers where necessary. It seems there were various bugs over the years where either these were either converted incorrectly or multiple ‘Status’ headers were sent at once – however all those bugs seem to be fixed now. So I think you’re safe just setting the HTTP style headers and letting PHP convert them.

    Also I just tested and sending the header(“HTTP/1.0 404 Not Found”); works fine on my dev environment using FastCGI

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Usually when I need to fork in C, I do something like this: pid_t
when releasing an instance that could exist or not, I usually write this: if
I build various web applications in PHP. Clients usually have the need for sending
Salesforce can send up to 100 requests inside 1 SOAP message. While sending this
Usually when I build a site, I put all the CSS into one file,
Usually when defining a DAO, you would have a setter for the datasource on
I usually have to deal with a lot of people sending me Windows files
I found that this works sporadically, but usually doesn't work at all. $(window).unload(function() {
There doesn't seem to be an accepted way of sending down a header parameter
When sending two UDP messages to a computer on Windows 7, it looks like

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.