Why not just let the user worry about that? Either they have a browser that supports opening the files and displaying the content, or they download the file, and then open it with some kind of Office app.
Jul 13, 2024
5
Level 5
How to open *.docx file with editor of the OS?
On laravel 10 / filament 3 site I create and save *.docx file with "Word2007" format using phpoffice/phpword library under site storage(I keep path of the generated file). After saving of the file I need to open the file with editor which is used for this type of file in the OS of the user. I search OS independeble desicion . How can I do it ?
"php": "^8.2",
"filament/filament": "^3.2-stable",
"laravel/framework": "^10.48.14",
"phpoffice/phpword": "^1.2"
Thanks in advance!
Please or to participate in this conversation.