Merge pull request #17578 from liviuconcioiu/language
Fix PHP documentation links for Chinese (Simplified)
This commit is contained in:
commit
a8cc5d93c5
@ -162,7 +162,7 @@ class Core
|
||||
/* List of PHP documentation translations */
|
||||
$php_doc_languages = [
|
||||
'pt_BR',
|
||||
'zh',
|
||||
'zh_CN',
|
||||
'fr',
|
||||
'de',
|
||||
'ja',
|
||||
@ -173,7 +173,11 @@ class Core
|
||||
|
||||
$lang = 'en';
|
||||
if (isset($GLOBALS['lang']) && in_array($GLOBALS['lang'], $php_doc_languages)) {
|
||||
$lang = $GLOBALS['lang'];
|
||||
if ($GLOBALS['lang'] === 'zh_CN') {
|
||||
$lang = 'zh';
|
||||
} else {
|
||||
$lang = $GLOBALS['lang'];
|
||||
}
|
||||
}
|
||||
|
||||
return self::linkURL('https://www.php.net/manual/' . $lang . '/' . $target);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user