Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

XML: "&" behaves not as expected

Posted on 2004-04-28
7
Medium Priority
?
209 Views
Last Modified: 2010-04-17
Hi all...

We have an XML which contains the text "One word & another word".
It appears on the page as "One word&another word".

We already tried "One word & another word", the outcome again is "One word&another word".

The XML runs through a lot different scripts/packeges, not all done by us. I want to avoid to find the place where an interpreter has bug.

Question:
Any way to get the character "&" beside the "&"?

Thank you
0
Comment
Question by:Smoerble
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 

Author Comment

by:Smoerble
ID: 10938412
increased to 250  (urgent)
0
 
LVL 2

Expert Comment

by:SatanUK
ID: 10938544
try &

0
 
LVL 2

Expert Comment

by:SatanUK
ID: 10938583
it sounds like a problem with the white space tho you may need to put a   or   so it reads

"One word & another word"
or
"One word & another word"
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:Smoerble
ID: 10938872
Thanks for the answers...
it did not work, behaved as before...
increased to 500... hopefully there is any other way (beside including an image ;))
0
 
LVL 2

Accepted Solution

by:
SatanUK earned 2000 total points
ID: 10938934
this worked fine for me

<?xml version="1.0" encoding="utf-8" ?>
<test>
      <test2>One word&#32;&#38;&#32;another word</test2>
</test>

do you have the utf-8 ?

does it matter if its Cdata or does it have to be PCData ?
0
 

Author Comment

by:Smoerble
ID: 10938972
UTF-8: yes, we have.
CData/PCData? looking now into this.
0
 

Author Comment

by:Smoerble
ID: 10975569
Ok, it was the CData thing:
<NavigationText><![CDATA[IT &amp; Productivity]]></NavigationText>

Thanks a lot, 500 points for Satan from UK ;)))
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…
Introduction to Processes

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question