• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need some Thinking(JSP and XML)

 
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Let me brief quickly about the need for my question:
I have a xml file with key has the output from the database and property has the value that needs to be printed in a jsp page.
Say for example the following code: when db output is "M" it prints Male.



Now in my jsp (i dont think u need the program to get this xml property..) when i display the coresponding output for key ="S" i get the output: Student?s

I really dont know why how the "'" in xml gets converted to "?" in jsp..

Thanks in advance..

So need some suggestions and expertise views..
 
Marshal
Posts: 28177
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Probably because the character isn't really an apostrophe, but some other character that looks a lot like it. Common culprits for this problem are Microsoft Word "smart quotes" that are pasted into XML documents. Those characters can't be represented in most charsets so they get converted into question marks.
 
Balaji Sampath
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I try to replace the code with ' wherever i need an apostrophe and got it solved.

Regards
Balaji.S
 
Bring out your dead! Or a tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic