Skip to Content
0

formattedtextview stripping text.

May 09, 2017 at 07:20 PM

64

avatar image
Former Member

I'm populating a formattedtextvie with a data source that has this in it

<h2>Safe & Secure Communities<ul><li>Sheriff Effective Service</li></ul></h2>

In partnership with the citizens of Some County, the <span style="color:#ff0000;"><b>Some County Sheriff's Office</b></span> will provide effective Public Service to all, holding everyone accountable in an impartial, ethical & professional manner.

However when FORMATTEDTEXTVIEW_CHART.setHtmlText = the above

This is what I get when in inspect the HTML

<h2>Safe & Secure Communities<ul><li>Sheriff Effective Service</li></ul></h2>

In partnership with the citizens of Some County, the <span ></span> will provide effective Public Service to all, holding everyone accountable in an impartial, ethical & professional manner.

As you can see the H2 and UL LI all work but it strips the text in the span and removes the formatting of the span. Can anyone tell me what is going on here or how I can fix it?

Thanks

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
Mike Howles
May 09, 2017 at 09:44 PM
0

According to the Design Studio User Guide, span tags are supported:

https://help.sap.com/viewer/c855e08c1a274d51ab4f0463dfdd9c40/1.6.4.0/en-US/4442c6ca1a4f4e65b72279d61755fff6.html

However it doesn't appear to like a bold tag inside of a span tag. Try removing that to get the text back. Regarding the inline styles, it appears only a certain subset are supported. Could you perhaps instead give your span a CSS class name and format that in your CSS file as a workaround? It will not strip a class name.

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member May 10, 2017 at 01:15 PM
0

Nice, I have never seen that page before. Also thanks for your contributions to SCN Community Extension.

Share
10 |10000 characters needed characters left characters exceeded