Javascript Word Add-In return broken special signs if switched encoding to utf-8 -
i build javascript addin word @ moment , run serious problems encoding. 1 of main functionalities of addin grab text word , send him server. in api word method gethtml()
grab text , convert html.
var body = context.document.body; var content = body.gethtml();
this working fine if encoding in word set default value. (western european) if switch encoding word document utf-8 method gethtml()
returns broken special signs. example: german broken special signs
mac: ö => √∂ ü => √º ä => √§ windows: ü => ü ö => ö ä => ä
two questions it:
if there possibility solve word api? seems bug , find no way return correct encodes html.
can fix problem javascript? tested around iconv lite found no solution.
Comments
Post a Comment