User Tools

Site Tools


uphp:functions:header

header

WMPRO, WMMINI FW >= 1.0 WMMEGA FW >= 2.0

Add to HTTP header

Description

header ( string $header_data )

This will add a header line to the HTTP response. Make sure that no data has been sent prior to calling header or else the function will fail. This means the opening tag <? has to appear at the very beginning of the file, if even a single space precedes it, the header function won't work.

Parameter

$header_data: String containing the specific header to be sent

Do not append a linefeed character (\n) as this is done automatically

Return Values

None

Example

<?
  // redirect to the main page (Dashboard or Login page):
  header("Location: /index.cgi");
?>
uphp/functions/header.txt · Last modified: 2021/09/13 05:57 (external edit)