wc_products_array_orderby_title()
Sort by title.
No Hooks.
Return
Int
.
Usage
wc_products_array_orderby_title( $a, $b );
- $a(WC_Product) (required)
- First WC_Product object.
- $b(WC_Product) (required)
- Second WC_Product object.
Changelog
Since 3.0.0 | Introduced. |
wc_products_array_orderby_title() wc products array orderby title code WC 9.3.1
function wc_products_array_orderby_title( $a, $b ) { return strcasecmp( $a->get_name(), $b->get_name() ); }