On 03/05/2013 03:52 PM, eric machine wrote:
>
> Could I use the API here
http://www.hylafax.org/content/HylaFAX_APIs
> to talk to Hylafax+?
Yes.
> So basically for microsoft office, I need to manually add this
> functionality into HylaFax+ right? But it is possible right?
Typically the filetype conversions are handled client-side so that the
server only has to deal with Postscript, PDF, or TIFF (and in some cases
PCL). If you really, really wanted to burden the server with the
MSOffice -> PDF conversions, then you're welcome to modify the code.
However, I would think that this is something you'd still want done on
the client.
If you're using the sendfax client then sample conversion approaches are
already in typerules. Here is a more-elaborate example...
-----------------------------------------
# MS Office (Word) conversion using antiword or unoconv. Install
antiword or unoconv
# (which uses OpenOffice/LibreOffice) and enable this if you want it.
It may produce
# imperfect renderings, but they're better than nothing, perhaps.
#0 short 0xd0cf ps antiword -p letter -m
8859-1.txt %i > %o
0 short 0xd0cf pdf unoconv -f pdf -o %o %i
#0 short 0xd0cf error Microsoft Word Document
support not configured
# Office 2007 uses a zipped Open-XML file format. Magic typing
# cannot distinguish between those files and other zip v2.0 files.
0 long 0x504b0304 error filetype conversion support
not configured
#>4 byte 0x14 error Zip v2.0 support not
configured
>4 byte 0x14 pdf unoconv -f pdf -o %o %i
0 filename ^.*\.[Dd][Oo][Cc]$ pdf unoconv -f pdf
-o %o %i
0 filename ^.*\.[Dd][Oo][Cc][Xx]$ pdf unoconv -f pdf
-o %o %i
0 filename ^.*\.[Xx][Ll][Ss]$ pdf unoconv -f pdf
-o %o %i
0 filename ^.*\.[Xx][Ll][Ss][Xx]$ pdf unoconv -f pdf
-o %o %i
0 filename ^.*\.[Rr][Tt][Ff]$ pdf unoconv -f pdf
-o %o %i
-----------------------------------------
Please note that the "filename" typing is a HylaFAX+ feature.