Ver Mensaje Individual
  #3 (permalink)  
Antiguo 03/09/2009, 15:53
pepepercebe
 
Fecha de Ingreso: diciembre-2005
Mensajes: 92
Antigüedad: 18 años, 4 meses
Puntos: 0
Respuesta: Como buscar por id dentro de responseXML

Gracias Gator, tu siempre estas ahí...

A ver, yo en la funcion ajax que recibe el responseXML tengo lo siguiente:

Código:
var documento  = ajax.responseXML;
// y de prueba estoy haciendo alerts para ver si accedo al atributo 
que quiero,siguiendo el ejemplo anterior quiero el valor del 'atributo1' 
que tiene el elemento con id 'modelo3'

var aaa = documento.getElementById('modelo3');
alert(aaa.getAttribute('atributo1'));
Y con este alert., el firebug me da el error "aaa is null alert(aaa.getAttribute('atributo1')); "