mirror of
https://github.com/php/web-php.git
synced 2026-03-23 23:02:13 +01:00
- Remember the last selected language from the langchooser on every
manual page.
This commit is contained in:
@@ -54,6 +54,9 @@ function language_choose_code()
|
||||
// Specified for the request (GET/POST parameter)
|
||||
if (isset($_REQUEST['lang'])) {
|
||||
$explicitly_specified = language_add($_REQUEST['lang'], $languages);
|
||||
|
||||
// Set the language in a cookie for a year and for all *.php.net servers
|
||||
setcookie("MYPHPNET", $_REQUEST['lang'], time() + 60*60*24*365, '/', '.php.net');
|
||||
}
|
||||
|
||||
// Specified in a shortcut URL (eg. /en/echo or /pt_br/echo)
|
||||
|
||||
Reference in New Issue
Block a user