?
Solved

XML: "&" behaves not as expected

Posted on 2004-04-28
7
Medium Priority
?
208 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
Get real performance insights from real users

Key features:
- Total Pages Views and Load times
- Top Pages Viewed and Load Times
- Real Time Site Page Build Performance
- Users’ Browser and Platform Performance
- Geographic User Breakdown
- And more

 

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

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

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.
This article will show how Aten was able to supply easy management and control for Artear's video walls and wide range display configurations of their newsroom.
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
Suggested Courses

800 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