Currently, I'm using ng2FileSelect
for my file uploading in angular 4 projects. I looked up on the internet for the mime-type for allowing doc and docx, after What is a correct mime type for docx, pptx etc? reading through this, I made my changes as per the answer. But still, I'm facing the problem and I'm still unable to upload doc and docx files. Is there any other possible way to do so using ng2FileSelect
.
code
public allowedMimeType = ['application/pdf','application/msword',
'application/vnd.openxmlformats-officedocument.wordprocessingml.document'];
attachment: FileUploader = new FileUploader({
allowedMimeType: this.allowedMimeType,
});
this code is helping me only in the upload of pdf files, not with doc and docx.
Thanks in advance.