woocommerce_(order_type)_list_table_css_classes
Filters the list of CSS class names for the orders list table.
Usage
add_filter( 'woocommerce_(order_type)_list_table_css_classes', 'wp_kama_woocommerce_order_type_list_table_css_classes_filter', 10, 2 ); /** * Function for `woocommerce_(order_type)_list_table_css_classes` filter-hook. * * @param string[] $classes An array of CSS class names. * @param string $order_type The order type. * * @return string[] */ function wp_kama_woocommerce_order_type_list_table_css_classes_filter( $classes, $order_type ){ // filter... return $classes; }
- $classes(string[])
- An array of CSS class names.
- $order_type(string)
- The order type.
Changelog
Since 7.8.0 | Introduced. |
Where the hook is called
woocommerce_(order_type)_list_table_css_classes
woocommerce/src/Internal/Admin/Orders/ListTable.php 347-357
$css_classes = apply_filters( 'woocommerce_' . $this->order_type . '_list_table_css_classes', array_merge( parent::get_table_classes(), array( 'wc-orders-list-table', 'wc-orders-list-table-' . $this->order_type, ) ), $this->order_type );