HomeMenu
Jesus · Bible · HTML · CSS · JS · PHP · SVG · Applications

session_cache_limiter

Description

The session_cache_limiter of Session for PHP gets and/or sets the current cache limiter.

Syntax

session_cache_limiter(
    ?string $value = null
): string|false

Parameters

value

If value is specified and not null, the name of the current cache limiter is changed to the new value.

ValueHeaders
publicExpires: (sometime in the future, according session.cache_expire)
Cache-Control: public, max-age=(sometime in the future, according to session.cache_expire)
Last-Modified: (the timestamp of when the session was last saved)
private_no_expireCache-Control: private, max-age=(session.cache_expire in the future), pre-check=(session.cache_expire in the future)
Last-Modified: (the timestamp of when the session was last saved)
privateExpires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: private, max-age=(session.cache_expire in the future), pre-check=(session.cache_expire in the future)
Last-Modified: (the timestamp of when the session was last saved)
nocacheExpires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache

Return

Returns the name of the current cache limiter. On failure to change the value, false is returned.

Examples

1 · void

<?

$return = session_cache_limiter();

echo $return;
nocache

2 · value · previous

<?

$value = "private";

$return = session_cache_limiter($value);

echo $return;
nocache

3 · value · current

<?

$value = "private";

session_cache_limiter($value);

$return = session_cache_limiter();

echo $return;
private