ArrayIterator::ksort

(PHP 5 >= 5.2.0, PHP 7, PHP 8)

ArrayIterator::ksortOrdena las entradas por las claves

Descripción

public ArrayIterator::ksort(int $flags = SORT_REGULAR): true

Ordena las entradas por las claves.

Nota:

Si dos miembros se comparan como iguales, ellos mantendrán su orden original. Antes de PHP 8.0.0, su orden relativo en un array ordenado era indefinido.

Parámetros

flags

The optional second parameter flags may be used to modify the sorting behavior using these values:

Sorting type flags:

Valores devueltos

Siempre devuelve true.

Historial de cambios

Versión Descripción
8.2.0 The return type is true now; previously, it was bool.

Ver también

add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top