Tema: XML y PHP
Ver Mensaje Individual
  #1 (permalink)  
Antiguo 25/07/2008, 07:10
Avatar de frins
frins
 
Fecha de Ingreso: enero-2008
Ubicación: Osor, Girona
Mensajes: 227
Antigüedad: 16 años, 4 meses
Puntos: 5
Busqueda XML y PHP

Hola amigos, tengo un script php que "parasea" un XML, el script esta aquí: http://keithdevens.com/software/phpxml yo lo tengo en la version 1.2b.

Yo estoy haciendo este script:
Código PHP:
 //Arxius
   
require('includes/inc.xml.php');
   
$file 'rss.xml';
   
$xml file_get_contents($file);
   
   
//Dades
   
$data XML_unserialize($xml);
   
$web_title $data['rss']['channel']['title'];
   
$web_link  $data['rss']['channel']['link']; 
   
$web_copyright $data['rss']['channel']['copyright']; 
   
$item_title $data['rss']['channel']['item']['title']; 

   
// Mostrar
   
echo '<div class="titol">'.$web_title.'</div>';
   echo 
'<div class="enllaç_pres"><a href="'.$web_link.'">'.$web_link.'</a></div>';
   echo 
'<div class="by">by:&nbsp;'.$web_copyright.'</div>';
   echo 
'<div class="titol">'.$item_title.'</div>';] 
Pero yo cuando quiero mostrar el $item_title, de RSS, no me lo muestra. Supongo que es porqu hay varios. ¿Sabeis cómo puedo hacer para diferenciar uno o otro, o cómo mostrarlos todos?
__________________
Buscador Net-Seekr
http://www.net-seekr.com