Hi
I am loading a list of images into a div with the following bit of jQuery :
var jewellerDdl = "<%= JewellerDropDownList.ClientID %>";
var filter = $("#" + jewellerDdl).val();
$.ajax({
type: "POST",
url: "popup.aspx/GetJewellerAssets",
contentType: "application/json; charset=utf-8",
data: '{"jewellerId":' + filter + '}',
dataType: "json",
success: AjaxSucceeded,
error: AjaxFailed
});
function AjaxSucceeded(result) {
$("#divEntryDisplay").text(result.d);
}
function AjaxFailed(result) {
alert(result.status + ' - ' + result.statusText);
}
The string I get back is a <ul>
containing a few images
However, the .text method doesnt add them to the dom. Instead it just prints the HTML as text inside the <div>
called divEntryDisplay
What have I done wrong?