So, I need to compare 2 strings ... the descriptio...
# suitescript
d
So, I need to compare 2 strings ... the description from a NetSuite line
Benzonase, purity grade II (>90%) for biotechnology
to an incoming CSV line
Benzonase, purity grade II (>90%) for biotechnology
... so, the question is, how can I force the
>
to convert to
>
so that these will match?
Is there a 'decode' or 'unescape' equivalent function in NetSuite?
p
There’s loads of different ways of doing this on SO: https://stackoverflow.com/questions/5796718/html-entity-decode One of them will work, maybe
d
So, lodash and _.unescape
s
SA 14563 mentions a few global functions, available in both SS 1 and 2, for encoding and decoding URI’s: encodeURI/decodeURI, escape/unescape, & encodeURIComponent/decodeURIComponent
I have not used them, though, so no idea how well they actually work
d
Interesting
n