Naturally orders available widgets by name.
Parameters
$widget_a
arrayrequired- The first widget to compare.
$widget_b
arrayrequired- The second widget to compare.
Source
protected function _sort_name_callback( $widget_a, $widget_b ) {
return strnatcasecmp( $widget_a['name'], $widget_b['name'] );
}
Changelog
Version | Description |
---|---|
3.9.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.