Automattic\WooCommerce\Internal\Admin

CategoryLookup::define_category_lookup_tables_in_wpdb()public staticWC 1.0

Add category lookup table to $wpdb object.

Метод класса: CategoryLookup{}

No Hooks.

Return

null. Nothing.

Usage

$result = CategoryLookup::define_category_lookup_tables_in_wpdb();

Code of CategoryLookup::define_category_lookup_tables_in_wpdb() WC 7.1.0

public static function define_category_lookup_tables_in_wpdb() {
	global $wpdb;

	// List of tables without prefixes.
	$tables = array(
		'wc_category_lookup' => 'wc_category_lookup',
	);

	foreach ( $tables as $name => $table ) {
		$wpdb->$name    = $wpdb->prefix . $table;
		$wpdb->tables[] = $table;
	}
}