How to handle special character like Japanese in an incoming email ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2019 07:47 PM
Hello all,
I recently has an issue with incoming email contain special character like Chinese or Japanese, ServiceNow does not recognize it and translate it to ���. Is there a way to fix this issue ?
- Labels:
-
Multiple Versions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2019 08:19 PM
Hi,
filter out the non-ascii characters and replace them with empty string
sample script below
var data = your string value
data = data.replace(/[^\x20-\x7E]+/g, ""); // only allow ascii chars
Mark ✅ Correct if this solves your issue and also mark 👍 Helpful if you find my response worthy based on the impact.
Thanks
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2019 09:07 PM
I do not want them to become an empty string, because I have to map the info to incident fields (description, short desc...).
I want it become a 'readable' text, like the above text
'以上、宜しくお�い致します。'
it should be
'以上、宜しくお願い致します。'
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-23-2019 12:35 AM
The issue is not in ServiceNow side, you have to config the encoding part in host emails like Outlook as this URL.
However, not all host emails have this config, so I am not sure if we can do anything on ServiceNow side ?