Skip to content
This repository was archived by the owner on Jan 8, 2022. It is now read-only.
njlg edited this page Jan 13, 2013 · 1 revision

header — Send a raw HTTP header

Note: Currently, this does not work to set the Content-Type header. Also, you cannot use this function to change the status code message.

Prototype

void header( string header [, int http_response_code] )

Parameters

header — The header string.

http_response_code — Forces the HTTP response code to the specified value.

Return Values

No value is returned.

Examples

header("X-Powered-By: Squrriel");
// and/or
header("Location: somethingelse.nut", 302);
// and/or
header("Cache-Control: no-cache, must-revalidate");
// and/or
header("Expires: Sat, 26 Jul 1997 05:00:00 GMT");

Clone this wiki locally