wpseek.com
WordPress开发者和主题制作者的搜索引擎



esc_html__ › WordPress Function

Since2.8.0
已弃用n/a
esc_html__ ( $text, $domain = 'default' )
参数: (2)
  • (string) $text Text to translate.
    Required: Yes
  • (string) $domain Optional. Text domain. Unique identifier for retrieving translated strings. Default 'default'.
    Required: No
    默认: 'default'
返回:
  • (string) Translated text.
定义在:
文档:

Retrieves the translation of $text and escapes it for safe use in HTML output.

If there is no translation, or the text domain isn't loaded, the original text is escaped and returned.


源码

function esc_html__( $text, $domain = 'default' ) {
	return esc_html( translate( $text, $domain ) );
}