- json_decode: documentation ( source)
- ksort: documentation ( source)
- join: documentation ( source)
<?php
$arr=json_decode('{"account":"user12","date":"2012-10-01 12:32:00","paymentType":"mc","projectId":"519","sum":"10.00","sign":"9bdf52a4830779a1383ac24f1b3ed054","unitpayId":"1234567","profit":"10.00"}');
$arr = array($arr);
ksort($arr);
echo join(null,$arr);