var d;
$("#ing").keyup(function(){
d= $("#ing").val();
$("#lipu").html(d);
});
This is the code i am using to change the text inside the div dynamically:
hljs.initHighlightingOnLoad();
This line of code helps in syntax highlighting when the code is hardcoded in the tags and works perfectly when page loads.
I want to do the exact same thing when I write the text inside the textbox and the highlighted text be displayed inside the div
I have tried to use following functions
hljs.initHighlighting.called = false;
hljs.initHighlighting();
But it did not work...
Please help I know there is a very simple solution but I couldn't find it on internet....