Manual:$wgCookiePrefix

From MediaWiki.org
Jump to navigation Jump to search
This page is a translated version of the page Manual:$wgCookiePrefix and the translation is 30% complete.

Other languages:
Deutsch • ‎English • ‎español • ‎français • ‎polski • ‎português • ‎русский • ‎հայերեն • ‎日本語 • ‎한국어
Cookies: $wgCookiePrefix
Custom cookie prefix.
Introduzida na versão:1.13.0 (r37893)
Removida na versão:ainda em uso
Valores permitidos:(string) or false
Valor por omissão:false
Outras configurações: Lista Alfabética | Lista por Função

Detalhes

Prefix for cookies and similar browser data (including localStorage). Set it to use a custom one. Setting it to false or an empty string sets the default of using the database name. Code should ensure browser saved data is prefixed with this value (this is currently done automatically only when WebResponse->setcookie is used without a custom prefix).

The default value is determined in Setup.php :

if ( !$wgCookiePrefix ) {
        if ( $wgSharedDB && $wgSharedPrefix && in_array( 'user', $wgSharedTables ) ) {
                $wgCookiePrefix = $wgSharedDB . '_' . $wgSharedPrefix;
        } elseif ( $wgSharedDB && in_array( 'user', $wgSharedTables ) ) {
                $wgCookiePrefix = $wgSharedDB;
        } elseif ( $wgDBprefix ) {
                $wgCookiePrefix = $wgDBname . '_' . $wgDBprefix;
        } else {
                $wgCookiePrefix = $wgDBname;
        }
}

Ver também