java在浏览器打开word,如何直接在浏览器中打开word文档

acid

when i run this the word document is not opening in a browser

解决方案

By default browser does not understand every type of files - Word documents is one of them...

How it opens them? The browser reads the mime-type of the file, looks into the OS to find a registered application that understand that mime-type and passes activates the application with the content of that file...

There is a possibility to create a plugin that actually adds a file viewer to the browser (like Adobe's pdf viewer) but Microsoft do not supply such plugin...

So it is not in your hand, and can not be forced by you...

你可能感兴趣的:(java在浏览器打开word)