Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Special Characters in XML

 
L Goundalkar
Ranch Hand
Posts: 395
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
How can i take care of special characters like meu ( dont know how to display the same here ) in XML.
what character set i have to set to my docuemnt object and how to set the same?
Thanks for the time.
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You need to replace the special characters with character references of the form &#nnnn; (for example, ] means "]").
You specify the document's character set with the XML declaration:
<?xml version="1.0" encoding="UTF-8"?>
[ November 06, 2003: Message edited by: Lasse Koskela ]
 
L Goundalkar
Ranch Hand
Posts: 395
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there any method in DOM API to set the character encoding ?
Thanks.
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try this:
 
L Goundalkar
Ranch Hand
Posts: 395
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thats Nice.. Its working fine. Thanks again.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic