XmlElement issue (raw data ?)


#1

Hi Guys,

I have an issue using XmlElement with an xml file.

I have some xml file with descriptions in it.
In order to format the text description, we have used some html tags like
this is a desc
another line of desc

So far I didn’t found a way using XmlElement
to retrieve the complete text I’m looking :
this is a desc
another line of desc

Any idea ?

Thanks,


#2

Well that
isn’t actually text at all, it’s a tag, so it’ll get parsed out. You’d just have to iterate the sub-elements, concatenating the text and looking for special tags like this, and doing whatever’s necessary with them.


#3

you need to encode the HTML such that the parser isn’t trying to treat it as XML.

Just pattern replace <> and / to


& # 60 ;
& # 62 ;
& # 47;

[edit] - stupid phpbb replaced the codes with the actual characters… You’ll need to remove the spaces… :roll:


#4

Damn, it’s been a while since I was beaten to a post by Jules like that. Such memories. :slight_smile:


#5

oki doki.

Thanks.


#6

ah - I might have been quicker, but valley’s suggestion was better than mine…