I'm very new to Json and JQuery. I got autocomplete Jquery UI plugin that return a Json Object. Ex it return ["Tim ferriss","stack overflow","<strong>Oscar</strong> Wilde"]
In the browser the strong tag is seen as <strong>Osca</strong>r Wilde
Why? I think is a very stupid error..
Edit: Nothing worked so far.This is the code
function highlight(s, t) {
var matcher = new RegExp("("+$.ui.autocomplete.escapeRegex(t)+")", "ig" );
return s.replace(matcher, "<strong>$1</strong>");
}
I think that json object is converted in a javascript object. I have the same issue anyway