XLS/XLSX not opening in IPAD/Safari created with APACHE POI
I developed a download functionality in a web application where a user can download selected records in excel file or in text file.
Everything is working fine in windows (All browsers) but in IPAD (Safari) download in excel functionality is not opening, saying unable to read document (An error occurred while reading the file). However, text download is working fine.
I goggled and found it might be due to some encryption in the file. Then I have changed the file extension from "xls" to "xlsx". But still its not working.
Is there any limitation with APACHE POI API? Because, I am able to open a normal xls/xlsx file in IPAD but not the programmaticaly created once.
Setting mime mappings in web.xml -
<mime-mapping>
<extension>
xls
</extension>
<mime-type>
application/vnd.ms-excel
</mime-type>
</mime-mapping>
<mime-mapping>
<extension>
xlsx
</extension>
<mime-type>
application/vnd.ms-excel
</mime-type>
</mime-mapping>
Also, in weblogic config we have mimemappings.properties.
链接地址: http://www.djcxy.com/p/46884.html上一篇: PHP