Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Re: XML parsing problem

Reply
Thread Tools

Re: XML parsing problem

 
 
Thomas Weidenfeller
Guest
Posts: n/a
 
      09-01-2003
Kevin Pors <(E-Mail Removed)> writes:
> <comments>http://www.battle.net/forums/thread.aspx?ForumName=d2-europe-trading&ThreadID=62916</comments>


<comments>http://www.battle.net/forums/thread.aspx?ForumName=d2-europe-trading&amp;ThreadID=62916</comments>

You want to read a little bit about the basics of XML, especially this
part of the standard:

http://www.w3.org/TR/REC-xml#syntax

/Thomas
 
Reply With Quote
 
 
 
 
Kevin Pors
Guest
Posts: n/a
 
      09-01-2003
On Mon, 1 Sep 2003 11:43:26 +0000 (UTC), http://www.velocityreviews.com/forums/(E-Mail Removed)lid (Thomas Weidenfeller) wrote:

> <comments>http://www.battle.net/forums/thread.aspx?ForumName=d2-europe-trading&amp;ThreadID=62916</comments>


Okay, I've tried that, but when parsing this I get this in return in the JTable:

ThreadID=62916

instead of the whole thing (including the &amp.
I guess I have to look for ampersands in the XML file so I can convert them right?

 
Reply With Quote
 
 
 
 
Sigmund Lundgren
Guest
Posts: n/a
 
      09-02-2003
Kevin Pors wrote:
> On Mon, 1 Sep 2003 11:43:26 +0000 (UTC), (E-Mail Removed)lid (Thomas Weidenfeller) wrote:
>
>
>><comments>http://www.battle.net/forums/thread.aspx?ForumName=d2-europe-trading&amp;ThreadID=62916</comments>

>
>
> Okay, I've tried that, but when parsing this I get this in return in the JTable:
>
> ThreadID=62916
>
> instead of the whole thing (including the &amp.
> I guess I have to look for ampersands in the XML file so I can convert them right?
>


Did you use a CDATA section?

/S

 
Reply With Quote
 
Kevin Pors
Guest
Posts: n/a
 
      09-02-2003
On Tue, 02 Sep 2003 22:15:38 GMT, Sigmund Lundgren <(E-Mail Removed)> wrote:

>Did you use a CDATA section?
>
>/S


No. But I started using conversion. Like a '&' would be changed to a String :AMP: in the
XML file. When I parse it, i change the :AMP: back to an ampersand. Got the same when a user
enters a '>' or a '<' sign. '<' would change to :GT: and '>' to :LT:
I don't think i need more for this to work well i guess

Easier methods would be preferred though


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
What libraries should I use for MIME parsing, XML parsing, and MySQL ? John Levine Ruby 0 02-02-2012 11:15 PM
Different results parsing a XML file with XML::Simple (XML::Sax vs. XML::Parser) Erik Wasser Perl Misc 5 03-05-2006 10:09 PM
Sequential XML parsing with xml.sax peter@hardy.dropbear.id.au Python 2 08-24-2005 01:29 AM
Clarification on XML parsing & namespaces (xml.dom.minidom) Greg Wogan-Browne Python 1 01-28-2005 03:19 AM
Print XML parsing to JspWriter (out) Class org.xml.sax.helpers.NewInstance can not access a member of class javax.xml.parsers.SAXParser with modifiers "protected" Per Magnus L?vold Java 0 11-15-2004 02:27 PM



Advertisments