knockout.js - Rerender as HTML - JSON databind not supporting HTML - displaying tags -


working on application using knockout data binding. i'm not versed in data binding or front end stuff matter. have json data being pulled in , binded. looks after bind:

<span data-bind="text: servicename"><a href="tst.com">here</a></span> 

and displays html tags on page shown:

<a href="tst.com">here</a>

the application have aspect uses data binding in similar fashion , supports html. i'm guessing kind of attribute or function force plain text?

my questions:

  • what should looking conversion?

  • is there way re-render html via js after page has loaded?

you can use html binding that.

http://knockoutjs.com/documentation/html-binding.html

<span data-bind="html: servicename"></span> 

this render value of servicename html inside span.


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

dataset - MPAndroidchart returning no chart Data available -

post - imageshack API cURL -