Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How can I send content textboxes with JavaScript as Unicode?

0
Posted

How can I send content textboxes with JavaScript as Unicode?

0

When you use ‘XMLHttpRequest’ object to send content to OpenCalais, the content needs to be encoded. The default escape() function of JavaScript is for English only but not enough for other languages, as it converts to ASCII instead of Unicode. Therefore you need to use: encodeURIComponent(). Passing the content of the textbox with this function creates a string with Unicode characters that will be parsed correctly on the server side of OpenCalais.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123