I am trying to make preview from base64 data . Here it works for any base64 image but if I use base64 pdf then it shows plugin is not supported . Here is my code . There is a post which closely similar but did not meet up my expectation.
if(response.responseCode == 1)
{
$("#image-info-content").html('<object data="'+response.data+'"></object>');
$('#image-modal').modal();
}
I also tried with type="application/pdf" . Still it's not working. Though I don't want this because there might be image or pdf file. Thanks in advance
response.data like here data:application/pdf;base64,JVBERi0xLjMKJeLjz9MKMSAwIG9iago8.......