mirror of
https://github.com/php/web-php.git
synced 2026-03-23 23:02:13 +01:00
Remove special cases for the gettext shorthand function (#1029)
- Related to https://github.com/php/doc-en/pull/3556
This commit is contained in:
committed by
GitHub
parent
115441182f
commit
96d1508e8f
@@ -400,7 +400,6 @@ $uri_aliases = [
|
||||
"links" => "support", // BC
|
||||
"links.php" => "support", // BC
|
||||
"oracle" => "oci8",
|
||||
"_" => "function.gettext",
|
||||
"cli" => "features.commandline",
|
||||
|
||||
"oop" => "language.oop5",
|
||||
|
||||
@@ -126,10 +126,8 @@ function find_manual_page($lang, $keyword)
|
||||
// English one in case no page is found
|
||||
$langs = ($lang != 'en') ? [$lang, 'en'] : ['en'];
|
||||
|
||||
// Reformat keyword, drop anything in parenthesis --- except a search for the underscore only. (Bug #63490)
|
||||
if ($keyword != '_') {
|
||||
$keyword = str_replace('_', '-', $keyword);
|
||||
}
|
||||
// Reformat keyword, drop anything in parentheses
|
||||
$keyword = str_replace('_', '-', $keyword);
|
||||
if (strpos($keyword, '(') !== false) {
|
||||
$keyword = preg_replace("!\\(.*\\)!", "-", $keyword);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user