function _tft_array_weight_sort in Taxonomy File Tree 7.2
Same name and namespace in other branches
- 7 tft.module \_tft_array_weight_sort()
Helper function to sort item arrays with usort().
Related topics
1 string reference to '_tft_array_weight_sort'
- tft_folder_content in ./
tft.module - Loads the given folder content.
File
- ./
tft.module, line 926 - Hook implementations and module logic for TFT.
Code
function _tft_array_weight_sort($a, $b) {
if ($a['weight'] != $b['weight']) {
return $a['weight'] < $b['weight'] ? -1 : 1;
}
return 0;
}