I need to induce a style property (color) to a selected text in a html div. This html div is created dynamically and is not accessible as a DOM element. Is there a way to do this ?
I have tried this : - inducing a html span (having the required style) along with the selected text.
String data="hello";
String sig= "its me !!"+" + data +
"";
widget.setData(sig);
I need the data alone in orange color. The widget internally handles the dynamic creation of the required div.
The characters "<" and ">" is converted to "<" and ">" and is shown as text instead of the span element. Is there a way to fix this. ?
Is there any way to inject HTML as string?
No comments:
Post a Comment