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



wp_style_is ›

Since2.8.0
已弃用n/a
wp_style_is ( $handle, $list = 'enqueued' )
参数: (2)
  • (string) $handle Name of the stylesheet.
    Required: Yes
  • (string) $list Optional. Status of the stylesheet to check. Default 'enqueued'. Accepts 'enqueued', 'registered', 'queue', 'to_do', and 'done'.
    Required: No
    默认: 'enqueued'
返回:
  • (bool) Whether style is queued.
定义在:
文档:

Check whether a CSS stylesheet has been added to the queue.



源码

function wp_style_is( $handle, $list = 'enqueued' ) {
	_wp_scripts_maybe_doing_it_wrong( __FUNCTION__ );

	return (bool) wp_styles()->query( $handle, $list );
}