I need to print MS Excel, MS Word and HTML files in a Linux CUPS server. When i try to print thses media types following occurs and this is what i've found till now:
For MS Excel and MS Word files:
When i try to print a file like these the error output is:
alvaro@alvaro-VM:~$ lp -d test_printer -o document-format=application/msword ptest.doc lp: Unsupported format 'application/msword'!
or, the same:
alvaro@alvaro-VM:~$ lp -d test_printer ptest.doc lp: Unsupported format 'application/msword'!
What i've found searching arround is that supposedly it is possible to use a CUPS filter, in this case the one i've found is called "officetop" (sourceforge/download link), taht would be possible to print MS OFFICE files. The problem i have with this "officetop" filter is that i don't know how to install it or counfigure it or whatever it needs to make it work and i couldn't find any tutorial or guide. So i wiil appreciate any help on this. Do you recommend use this filter to do this task? i'm open to any alternative solution.
For HTML files:
As a first test i made:
alvaro@alvaro-VM:~$ lp -d test_printer -o document-format=text/html index.html the requested id is test_printer-105 (1 archivo(s))
And, which gave the same result:
alvaro@alvaro-VM:~$ lp -d test_printer index.html the requested id is test_printer-106 (1 archivo(s))
index.html:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html><body><h1>It works!</h1> <p>This is a html print test.</p> </body></html>
Result: on the printed sheet you can see just de html code instead the formated text.
EDIT: If i print a web page from the web browser like chrome it gets well printed but If i download the web page with the browser option "Save web page as" and then issue *lp -d test_printer index.html* occours the same i mentioned before, just the html code gets printed.
Please help on this. what I want is to get the formated text it is posible. It is also possible to print HTML+CSS?.
Thank you very much guys.
Regards.
PD: sorry about my english.