WP_Dependencies::do_item() WordPress Method

The WP_Dependencies::do_item() method is used to process a single item in the dependency list. This includes both scripts and styles.

WP_Dependencies::do_item( string $handle, int|false $group = false ) #

Processes a dependency.


Parameters

$handle

(string)(Required)Name of the item. Should be unique.

$group

(int|false)(Optional) Group level: level (int), no group (false).

Default value: false


Top ↑

Return

(bool) True on success, false if not set.


Top ↑

Source

File: wp-includes/class.wp-dependencies.php

	public function do_item( $handle, $group = false ) {
		return isset( $this->registered[ $handle ] );
	}


Top ↑

Changelog

Changelog
VersionDescription
5.5.0Added the $group parameter.
2.6.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.