We help IT Professionals succeed at work.
Get Started

Where is 'header('Content-Type: text/xml');' actually 'sent' and other http/CGI(?) questions

SAbboushi
SAbboushi asked
on
398 Views
Last Modified: 2015-05-14
When I'm creating a response to an HTTP request and php executes a header call,

1) where exactly is that header field sent to?

I suspect it is to the Web Server that is managing the connection... so I imagine the Web Server (e.g. Apache) is assembling/buffering the http response as the php script sends it, possible in pieces.

2) Is that how it works?

3) If so, is there some place to examine the Apache buffer where said response as it is being 'built' by php/html output?

4) What is the event that tells Apache the response is complete and to send it?

Please correct any errors in my wording/naming of things as I try to better understand how this all works.  Thanks--
Comment
Watch Question
Consultant
CERTIFIED EXPERT
Commented:
This problem has been solved!
Unlock 2 Answers and 12 Comments.
See Answers
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE