Jump to content

  • Log in with Facebook Log in with Twitter Log In with Google      Sign In   
  • Create Account

Subscribe to HRA Now!


Are you a Google Analytics enthusiast?

Share and download Custom Google Analytics Reports, dashboards and advanced segments--for FREE! 




From the folks who brought you High Rankings!

- - - - -

What Is Header() Function In Php?

  • This topic is locked This topic is locked
2 replies to this topic

#1 ifuturzcom


    HR 1

  • Members
  • Pip
  • 1 posts

Posted 21 May 2012 - 02:08 AM

what is Header() function in PHP and For what is this function used in PHP language?

#2 chrishirst


    A not so moderate moderator.

  • Moderator
  • 7,659 posts
  • Location:Blackpool UK

Posted 21 May 2012 - 03:50 AM


It is used for sending HTTP headers and response codes to the user agent that is requesting data.

#3 MaxPowers


    HR 1

  • Members
  • Pip
  • 1 posts
  • Location:Wisconsin Dells, WI

Posted 30 July 2012 - 05:32 PM

It can send HTTP 'instructions' to redirect to a new page, force a file to download, respond to if-then-modified headers and decide to change the HTTP status of a file to 304 (Not Modified) or any other HTTP status code (200, 301, 302, 404, etc), it can declare the size of a document in bytes, the last time a file was updated, or change it to a specific type for images, spreadsheets, HTML, sound, video, and more. It can be used to change cache settings for files and webpages on your server.

I've even used it as a really geeky joke to add header information to a file transfer, which is never really looked at by those receiving the files..."x-Joke-Of-The-Day: A man walks into a bar..."

In other words, it can be used to control a lot of really cool functionality and optimizations on your website using HTTP Scripting.

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

If you are just registering to spam,
don't bother. You will be wasting your
time as your spam will never see the
light of day!