Difference between revisions of "JArrayHelper::sortObjects"

From Joomla! Documentation

(Bulk upload by Doxiki2)
(Layout updates)
Line 50: Line 50:
array The sorted array of objects
array The sorted array of objects
===Defined in===
===Defined in===
libraries/joomla/utilities/arrayhelper.php (line 294)
* see source code in [[jplatform:utilities/arrayhelper.php#cl-294|BitBucket]]
===Referenced by===
===Referenced by===
===See also===
===See also===

Revision as of 19:55, 23 April 2011

Replacement filing cabinet.png
This Namespace has been archived - Please Do Not Edit or Create Pages in this namespace. Pages contain information for a Joomla! version which is no longer supported. It exists only as a historical reference, will not be improved and its content may be incomplete.

Joomla 11.1 JArrayHelper::sortObjects


Utility function to sort an array of objects on a given field.

Description:JArrayHelper::sortObjects [Edit Descripton]


Joomla 11.1


public static JArrayHelper::sortObjects (&$a, $k, $direction=1, $casesensitive=true, $locale=false)
Parameter Type Default Description
&$a array $arr An array of objects
$k array The key or a array of key to sort on
$direction array 1 Direction or an array of direction to sort in [1 = Ascending] [-1 = Descending]
$casesensitive array true Let sort occur casesensitive or insensitive
$locale array false Let sort occur using the locale language or not


array The sorted array of objects

Defined in

libraries/joomla/utilities/arrayhelper.php (line 294)

Referenced by

See also

[Edit See Also]



<CodeExamplesForm />