Go Back   TechArena Community > Software > Software Development
Become a Member!
Forgot your username/password?
Tags Active Topics RSS Search Mark Forums Read

Reply
 
Thread Tools Search this Thread
  #1  
Old 14-09-2009
Member
 
Join Date: Apr 2008
Posts: 240
What is inside PHP Header file

I know that every header file contains the information about itself, its methods, version number and so on, but what the PHP header function contains inside it, Please let me know as I also need to mention in my PHP header file.
Reply With Quote
  #2  
Old 14-09-2009
Member
 
Join Date: Jan 2009
Posts: 140
Re: What is inside PHP Header file

In commons header() being used for page redirection whereby a specific location being define. However header() can be use more than just that. PHP has around hundreds of inbuilt for functions which makes it a very powerful language. A function is a group of statements that can be executed any time you want. ALL functions in PHP start with function(). These functions can also accept parameters. header() may also be use for page authentication assigning content type cache control etc.
Reply With Quote
  #3  
Old 14-09-2009
Member
 
Join Date: Feb 2006
Posts: 185
Re: What is inside PHP Header file

The header() function sends a raw HTTP header to a client.We can use herder() function for redirection of pages. It is important to notice that header() must be called before any actual output is seen. The reason for this problem is that headers is the first thing sent out by a page so you shouldn?t output anything before the header function(not even a html tag). But sometimes its hard to avoid that in situations where you have a login form and on the submission of form you want to verify the user and then redirect him.
Reply With Quote
  #4  
Old 14-09-2009
Member
 
Join Date: Dec 2008
Posts: 202
Re: What is inside PHP Header file

The main use of header() is to send header information into client machine and its one of the use is Page redirect we have a lot of directives for this function for Eg. Location. At the top of your php file in which you are using header redirect call the function ob_start() while output buffering is active no output is sent from the script (other than headers), instead the output is stored in an internal buffer. There are other Different arguments in php header function:-

The header() function sends a raw HTTP header to a client.

Syntax:
header(string,replace,http_response_code)
Reply With Quote
Reply

  TechArena Community > Software > Software Development
Tags: , , ,



Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "What is inside PHP Header file"
Thread Thread Starter Forum Replies Last Post
File Path insert on Header/Footer Office 2007 Allanoo MS Office Support 1 04-02-2013 04:20 PM
Connect USB 3.0 front case panel header to motherboard w/o a header? Dogs-Day-Out Motherboard Processor & RAM 4 14-04-2012 07:02 PM
How to open precompiled header file stating an error no such file found P-chuha Software Development 6 27-06-2011 07:19 AM
what is SWF file stands for? What does SWF file contains inside it? Benito Software Development 3 31-08-2009 12:38 PM
IIS7: Add expires header or cache-control header quota Software Development 3 06-06-2009 07:45 PM


All times are GMT +5.5. The time now is 09:57 PM.