JSON SORT WITH PHP

Posted on 16th Feb 2014 by admin

I have two products that I want to sort by say "Id:17, value: xxx" using php
The page will end up looking like this

Part Number Diameter Effective focal back focal cntr thickness edge thickness
L-AOC000 6.00 10.00 7.52 4.75 3.5

here is the decoded json for the two products ( there are a few hundred products)

{"id":"16","value":"L-AOC000"},{"id":"17","value":"6.00"},{"id":"18","value":"10.00"},{"id":"19","value":"7.52"},{"id":"20","value":"4.75"},{"id":"21","value":"3.50"}

{"id":"16","value":"L-AOC001"},{"id":"17","value":"7.00"},{"id":"18","value":"11.00"},{"id":"19","value":"8.52"},{"id":"20","value":"3.75"},{"id":"21","value":"2.50"}

any help would be appreciated

Other forums