Ver Mensaje Individual
  #2 (permalink)  
Antiguo 23/07/2009, 06:00
Avatar de gjx2
gjx2
 
Fecha de Ingreso: agosto-2008
Ubicación: R.D
Mensajes: 1.153
Antigüedad: 15 años, 8 meses
Puntos: 139
Respuesta: Ayuda con ARRAY

Crea un contador.


Código PHP:

$agentes 
= array("Manzana","Pera","Banana","Pepino","Durango","China","Naranja","Juelas","China1","Rulo","Habic","Uva");
$Contador 0;  ## Contador
foreach ($agentes as $id){

if(
$Contador == 4){
echo 
'<br>';
$Contador 0;
}


echo 
$id." ";


$Contador++;