hello, I forgot to say that this same code works in any class java. Thank you all for youre help.
-------- Original Message -------- Subject: trouble using DomParser in JSP Date: Thu, 05 Apr 2001 04:23:50 -0400 From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] HEllo, I'm trying to parse an XML document with DOm method into a JSP. I'm using the method hasAttributes from Node interface. but I'm always catching an Exception "Method hasAttributes() not found in interface org.w3c.dom.Node". the code that I'm including in my JSP is something like this: <% DOMParser dprDomParser = new DOMParser(); try{ dprDomParser.parse(new InputSource(new ByteArrayInputStream( strXml.getBytes()))); } catch(Exception expE){ expE.printStackTrace(); } /**********************************************************/ /* Code for retrieaving a node (nod) from the XmlDocument */ // etc... if (nod.hasAttributes()){ out.println("OK"); } else{ out.println("NO"); } %> __________________________________________________________________ Get your own FREE, personal Netscape Webmail account today at http://webmail.netscape.com/