Ver Mensaje Individual
  #4 (permalink)  
Antiguo 25/05/2009, 03:17
fatasma
Usuario no validado
 
Fecha de Ingreso: octubre-2008
Ubicación: BRUSELAS
Mensajes: 211
Antigüedad: 15 años, 6 meses
Puntos: 3
Respuesta: Extraer solo link o url

Código PHP:
<?php


$texte
='<div class="buttons">
<a href="http://filebucket.net/files/5083_0q6rj/Thalia - Por Amor.mp3"/> Descargar</a> 
</div>
<div class="buttons">
<a href="http://filebucket.net/files/5083_0q6rj/Thalia - Cantando por un sueno.mp3"/> Descargar</a> 
</div>
<div class="buttons">
<a href="http://filebucket.net/files/5083_0q6rj/Thalia - amor ala mexicana.mp3"/> Descargar</a> 
</div>
<div class="buttons">
<a href="http://filebucket.net/files/5083_0q6rj/Thalia - hola hola.mp3"/> Descargar</a> 
</div>'
;

preg_match_all('/<a href="(.*)"\/>/',$texte,$respuestas);



foreach(
$respuestas[1] as $valor)
{
    
$direccion=$valor;
    echo 
$direccion.'<br/>';
}
?>
suerte