You should be able to place any command-line options in a script (as below) and then select that script through the firefox
menu. However, it is critical you include "$@"
so that the file(s) passed from firefox
will actually be opened. Otherwise, just a blank document would be opened. As an example, this is the sort of wrapper script that you use:
#!/bin/bash
/usr/share/playonlinux/playonlinux --run "Microsoft Word 2010" Z:"$@"
It is critical to include the Z:
or the document will not be found by wine
or its equivalent, as the Z:
is a symlink to your filesystem.
I also tried this with WordViewer
in Wine
and it worked with the following commands:
#!/bin/bash
wine /home/mike/.wine/drive_c/Program\ Files/Microsoft\ Office/OFFICE11/WORDVIEW.EXE Z:"$@"
If you just wanted Libreoffice
, you would instead use in the script:
#!/bin/bash
libreoffice --writer "$@"
There is further detailed information in this useful article if you also wish to associate various file types with Microsoft Word 2010, as also discussed in this question:
Create a new text file, copy the contents of the first script (which is what you said you want) and make it executable. Then you can select the script through the firefox menu, as below:
