I have two elements that need to be updated a DIV and another INPUT
One has to be updated value and another the html, example
...
$.each(json, function (index, value) {
if (typeof $("#" + index).val() !== "undefined") {
$("#" + index).val(value);
} else {
if (typeof $("#" + index).html() !== "undefined") {
$("#" + index).html(value);
}
}
});
...
I'm doing the above but it's not working