Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

oj-bind-text html escape characters

Andrew BennettJun 14 2019 — edited Jun 14 2019

Hi Guys,

Wondering what the best way to render text on the page with escaped characters like © is so that it renders as Copyright © 2019

The following works:

<oj-bind-text value="[['Copyright &copy; 2019']]"></oj-bind-text>

This does not work, renders as Copyright &copy; 2019

<oj-bind-text value="[[copyrightNoticeText]]"></oj-bind-text>

self.copyrightNoticeText = ko.observable('Copyright &copy; 2019);

I need it to come from the JS as it's going to be translatable text, so option 1 is not viable.

I have looked at using the <oj-bind-dom> and this doesn't seem to work either, the only way is to use the knockout html binding. Is this the best approach at the moment?

Cheers,

Andy

This post has been answered by Duncan Mills-Oracle on Jun 14 2019
Jump to Answer
Comments
Post Details
Added on Jun 14 2019
2 comments
467 views