MediaWiki
REL1_19
|
Allow programs to request this object from WebRequest::response() and handle all outputting (or lack of outputting) via it. More...
Public Member Functions | |
header ($string, $replace=true, $http_response_code=null) | |
Output a HTTP header, wrapper for PHP's header() | |
setcookie ($name, $value, $expire=0, $prefix=null, $domain=null) | |
Set the browser cookie. |
Allow programs to request this object from WebRequest::response() and handle all outputting (or lack of outputting) via it.
Definition at line 28 of file WebResponse.php.
WebResponse::header | ( | $ | string, |
$ | replace = true , |
||
$ | http_response_code = null |
||
) |
Output a HTTP header, wrapper for PHP's header()
$string | String: header to output |
$replace | Bool: replace current similar header |
$http_response_code | null|int Forces the HTTP response code to the specified value. |
Reimplemented in FauxResponse.
Definition at line 37 of file WebResponse.php.
WebResponse::setcookie | ( | $ | name, |
$ | value, | ||
$ | expire = 0 , |
||
$ | prefix = null , |
||
$ | domain = null |
||
) |
Set the browser cookie.
$name | String: name of cookie |
$value | String: value to give cookie |
$expire | Int: number of seconds til cookie expires |
$prefix | String: Prefix to use, if not $wgCookiePrefix (use '' for no prefix) |
@domain | String: Cookie domain to use, if not $wgCookieDomain |
Reimplemented in FauxResponse.
Definition at line 49 of file WebResponse.php.
References $wgCookieDomain, $wgCookieExpiration, $wgCookieHttpOnly, $wgCookiePath, $wgCookiePrefix, $wgCookieSecure, wfDebugLog(), and wfHttpOnlySafe().