I want to display image by ajax jquery in this way so is that possible?
$.ajax({
url: "c.jpeg",
type :"get",
dataType: "image/jpeg",
success: function(data)
{
$("#myimg2").attr("src",data);
}
})
and this is the html
<body>
<img id="myimg2" ><br>
</body>
If that could be possible in some way. I want also to get the image from php file rather than directly jpeg file using this header.
header('content-type: image/jpeg');