PHP USORT KEEP KEYS
// Use "uasort" instead of "usort"
function order_asc($a, $b) {
return $b["popularity"] - $a["popularity"];
}
uasort(array, "order_asc");
Black Bug
// Use "uasort" instead of "usort"
function order_asc($a, $b) {
return $b["popularity"] - $a["popularity"];
}
uasort(array, "order_asc");