TransWikia.com

SP Online rest api canvascontent1 field: how to remove double escaping and encoding

SharePoint Asked by matt on July 31, 2020

Using search rest api to populate a react native mobile app, the JSON response for the canvascontent1 field that contains a page’s content, encodes, and in some cases, double escapes some of the html tags/characters.

For example, the iframe code for an embedded video is encoded and double escaped, so only a guid renders in the mobile app:

<iframe width=\"640\".....

Does the decoding and "unescaping" have to happen on the app end or is there some way to get "clean" html back in the response? Has anyone been able to figure this out?

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP