Ordenar Matriz

From: Date: Tue, 15 Jan 2008 17:36:17 +0000
Subject: Ordenar Matriz
References: 1  Groups: php.general.es 
Request: Send a blank email to general-es+get-62057@lists.php.net to get a copy of this message
Buenas tardes a todos. Tengo un caso en el que tengo una matriz (abajo les copio la estructura y datos) y necesitaría ordenarla por ejemplo por la posicion NOMBRE de manera ASCENDENTE o también por la posición FECHA de manera DESC y así. Estuve viendo algunas funciones, pero me preguntaba si conocían alguna función por ahí que me facilite el proceso. Muchas gracias. *Estructura y datos:* Array ( [0] => Array ( [0] => zxcv [nombre] => zxcv [1] => zxcv [apellido] => zxcv [2] => zxcv [empresa] => zxcv [3] => zxcv@zxcv.com [email] => zxcv@zxcv.com [4] => zxcv [comentario] => zxcv [5] => S [condiciones] => S [6] => [apartado] => [7] => 1409 [ip] => 1409 [8] => 2008-01-15 04:04:48 [fecha] => 2008-01-15 04:04:48 [9] => ca [idioma] => ca ) [1] => Array ( [0] => asdf [nombre] => asdf [1] => asdf [apellido] => asdf [2] => asdf [empresa] => asdf [3] => asdf@asdf.com [email] => asdf@asdf.com [4] => asdf [comentario] => asdf [5] => S [condiciones] => S [6] => [apartado] => [7] => 1404 [ip] => 1404 [8] => 2008-01-15 04:04:32 [fecha] => 2008-01-15 04:04:32 [9] => ca [idioma] => ca ) [2] => Array ( [0] => test [nombre] => test [1] => test [apellido] => test [2] => test [empresa] => test [3] => test@test.com [email] => test@test.com [4] => test [comentario] => test [5] => S [condiciones] => S [6] => [apartado] => [7] => 1531 [ip] => 1531 [8] => 2008-01-15 09:07:26 [fecha] => 2008-01-15 09:07:26 [9] => ca [idioma] => ca ) [3] => Array ( [0] => test [nombre] => test [1] => test [apellido] => test [2] => test [empresa] => test [3] => test@test.com [email] => test@test.com[4] => test [comentario] => test [5] => [condiciones] => [6] => [apartado] => [7] => 1526 [ip] => 1526 [8] => 2008-01-15 09:07:06 [fecha] => 2008-01-15 09:07:06 [9] => ca [idioma] => ca ) [4] => Array ( [0] => test [nombre] => test [1] => test [apellido] => test [2] => test [empresa] => test [3] => test [email] => test [4] => test [comentario] => test [5] => S [condiciones] => S [6] => [apartado] => [7] => 1522 [ip] => 1522 [8] => 2008-01-15 09:06:57 [fecha] => 2008-01-15 09:06:57 [9] => ca [idioma] => ca ) ) Emiliano J. Horcada

« previous php.general.es (#62057) next »