/ Published in: PHP
                    
                                        sort a multidimensional array by field
                
                            
                                Expand |
                                Embed | Plain Text
                            
                        
                        Copy this code and paste it in your HTML
 function array_field_sort(&$array, $field) { $code = "return strnatcmp(\$a['$field'], \$b['$field']);"; }
Comments
                    Subscribe to comments
                
                