WP_HTML_Open_Elements::has_element_in_table_scope( string $tag_name ): bool

Returns whether a particular element is in table scope.

Description

The stack of open elements is said to have a particular element in table scope when it has that element in the specific scope consisting of the following element types:

  • html in the HTML namespace
  • table in the HTML namespace
  • template in the HTML namespace

See also

Parameters

$tag_namestringrequired
Name of tag to check.

Return

bool Whether given element is in scope.

Source

 * @see https://html.spec.whatwg.org/#has-an-element-in-table-scope
 *
 * @param string $tag_name Name of tag to check.
 * @return bool Whether given element is in scope.
 */
public function has_element_in_table_scope( string $tag_name ): bool {
	return $this->has_element_in_specific_scope(
		$tag_name,
		array(
			'HTML',

Changelog

VersionDescription
6.7.0Full implementation.
6.4.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.