WC_Product_Variable::get_visible_children()

Return a products child ids – visible only.


Description Description

This is lazy loaded as it’s not used often and does require several queries.


Return Return

(array) Children ids


Top ↑

Source Source

File: includes/class-wc-product-variable.php

	public function get_visible_children() {
		if ( null === $this->visible_children ) {
			$children = $this->data_store->read_children( $this );
			$this->set_children( $children['all'] );
			$this->set_visible_children( $children['visible'] );
		}
		return apply_filters( 'woocommerce_get_children', $this->visible_children, $this, true );
	}

Top ↑

Changelog Changelog

Changelog
Version Description
3.0.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

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