I have AJAX Response for this call
<script type="text/javascript">
$(document).ready(function(){
$.ajax({
url : '<%=getChartData%>',
success : function(data){
document.write(data);
$.each(data, function(index, item) {
$('img').attr('src',data.item);
});
}
});
});
</script>
[E:\li\1.jpg,E:\li\2.jpg,E:\li\10.jpg] (**AJAX Response** )
With the Obtained response shown above , i am trying to replace all my img tags to contain the above dynamic source .
But this isn’t working , could anybody please help me .
I’m guessing the returned data is an array, and I assume you already know that there is a drive letter included in each result, and if it’s not supposed to be there you will have to remove it. Something like this should insert the images in the first ten image tags ?