I am more of a JS person so I wrote a page using JS. However, I later realized it would probably be better to do 99.9% of the stuff I needed to do server-side, but being rather new to PHP I need some help.
Below is a snippet where I create basically a multi-dimensional array and sort it by one of its inner values:
var sortedpts=[];
_.each(main.points,function(v,k){
sortedpts.push([k,v]);
});
sortedpts.sort(function(a,b){return b[1]-a[1];});
return sortedpts;
The whole structure is a long array (over 100 values) where each key contains an array of two values and I wish to sort by the latter of these. If you're confused here is a screenshot/example showing how my JS has sorted the main array by an inner value:

I'm kind of at a loss of how to sort this particular way in PHP. It seems that array_multisort may be involved in the solution. Any help?
usort