函数文档

wp_timezone_supported()

💡 云策文档标注

概述

wp_timezone_supported() 是一个已弃用的 WordPress 函数,用于检查 PHP 时区支持,但自 3.2.0 版本起始终返回 true。

关键要点

  • 函数 wp_timezone_supported() 已弃用,自 WordPress 3.2.0 版本起不建议使用。
  • 该函数返回布尔值,但弃用后始终返回 true,表示 PHP 时区支持已默认存在。
  • 弃用信息通过 _deprecated_function() 函数标记,开发者应避免在新代码中使用此函数。

📄 原文内容

Check for PHP timezone support

Return

bool

Source

function wp_timezone_supported() {
	_deprecated_function( __FUNCTION__, '3.2.0' );

	return true;
}

Changelog

Version Description
3.2.0 Deprecated.
2.9.0 Introduced.