Win a copy of Microservices Testing (Live Project) this week in the Spring forum!
  • 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
  • Tim Cooke
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Liutauras Vilda
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Mikalai Zaikin
  • Himai Minh

Special Characters

 
Ranch Hand
Posts: 112
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
OK...is it me or something else....

If someone copies �(Trademark) from word doc to a textfield and when I try to save that value in the DB, it converts into a '?'.

Then I tried to a round about, used the following replace function in javascript before submitting the form.

var r = replace(t, '�', '& # 1 5 3;');--numeric value

But this doesnot work, it refuses to identify � in the string entered by user.

Any light on this wil be GREATLY appreciated......

I wasted like 24 hrs on this....

Thanks
Rajani

[ June 14, 2006: Message edited by: Rajani Katta ]
[ June 14, 2006: Message edited by: Rajani Katta ]
 
Mini Pilla
Ranch Hand
Posts: 112
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Never mind.....I got it

var r = w.replace('�', String.fromCharCode(153));
[ June 15, 2006: Message edited by: Rajani Katta ]
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic