Ver Mensaje Individual
  #2 (permalink)  
Antiguo 15/07/2009, 09:02
Avatar de abimaelrc
abimaelrc
Colaborador
 
Fecha de Ingreso: mayo-2009
Ubicación: En el planeta de Puerto Rico
Mensajes: 14.734
Antigüedad: 17 años, 4 meses
Puntos: 1517
Respuesta: Expresiones regulares

Y si en vez de estar llamando trim($patron1[1][0]) en el for, creas una variable antes del for y le indicas que lo que quieres tener es lo que indicaste?

Código PHP:
$home = trim($patron1[1][0]);
for (
$row1 = 0; $row1 < $count1 ; $row1++) { 
    
$string = $home.trim($patron2[1][$row1]); 
    
$string = ereg_replace(" ", "", $string); 
    
$h = trim("http://".$string); 
    echo 
$h."<br>"; 
}