WordPress函数:language_attributes
一、函数简介
显示“html”标记的语言属性。(Displays the language attributes for the 'html' tag.)二、函数参数
* @param string $doctype Optional. The type of HTML document. Accepts 'xhtml' or 'html'. Default 'html'.三、函数案例
<?php language_attributes( $doctype = 'html' ) ?>
四、源代码
/**
* Displays the language attributes for the 'html' tag.
*
* Builds up a set of HTML attributes containing the text direction and language
* information for the page.
*
* @since 2.1.0
* @since 4.3.0 Converted into a wrapper for get_language_attributes().
*
* @param string $doctype Optional. The type of HTML document. Accepts 'xhtml' or 'html'. Default 'html'.
*/
function language_attributes( $doctype = 'html' ) {
echo get_language_attributes( $doctype );
}
THE END