WOOF_Collection :: by_number( String $name, String $order = "ASC", Boolean $case_insensitive = false, Boolean $clone = false )
A synonym for the WOOF_Collection::sort method, to sort the collection by the value of a property specified, preset to a forced numeric sort. A “property” here can be a genuine object property, or the result of a method call as handled by the WOOF_Wrap::get method.
Parameters:
-
The property name whose values will be used to sort by
-
String $order = "ASC"
The order to sort by, either “ASC” for ascending, or “DESC” for descending
-
Boolean $case_insensitive = false
Whether to ignore the case of the values when sorting
-
Boolean $clone = false
If true, the original collection will be untouched, and a clone of the sorted collection will be returned instead.