wp_get_update_php_annotation()
Проверено на WordPress 6.9, обновлено Источник: WordPress Developer Resources.
Сигнатура
wp_get_update_php_annotation(): string
Описание
Эту функцию следует использовать после wp_get_update_php_url(), чтобы вернуть единообразную аннотацию, если хостинг-провайдер изменил URL страницы «Обновление PHP» по умолчанию.
Оригинал (английский)
This function is to be used after wp_get_update_php_url() to return a consistent annotation if the web host has altered the default “Update PHP” page URL.
Возвращаемое значение
string
Исходный код
wp-includes/functions.php:8605
function wp_get_update_php_annotation() {
$update_url = wp_get_update_php_url();
$default_url = wp_get_default_update_php_url();
if ( $update_url === $default_url ) {
return '';
}
$annotation = sprintf(
/* translators: %s: Default Update PHP page URL. */
__( 'This resource is provided by your web host, and is specific to your site. For more information, <a href="%s" target="_blank">see the official WordPress documentation</a>.' ),
esc_url( $default_url )
);
return $annotation;
}
История изменений
| Версия | Описание |
|---|---|
| 5.2.0 | Introduced. |

