Thanks for the quick responses from David and Gilles.
The problem definitely fits your "wp2html is returning no output"
suggestion. Further experimentation confirms what I saw before: By
extracting the command line that doc2html generates and pasting it into the
command line, wp2html has no problem generating the html version of the
wordperfect file. But doc2html's attempt to use that same command line to
pipe back the results fails.
Martin Abell
NIOSH, CDC.
-----Original Message-----
From: David Adams [mailto:[EMAIL PROTECTED]]
Sent: Thursday, May 24, 2001 5:18 AM
To: Abell, Martin
Cc: htdig
Subject: Re: [htdig] doc2html not picking up wp2html output
Either doc2html.pl is not recognizing the file as WordPerfect or wp2html is
returning no output.
In this case I think the problem is with the MIME type, doc2html.pl looks
for
application/Wordperfect
while your server is sending
application/wordperfect
I think the solution is to make the checking of MIME type independant of
case.
Change the lines in try_html from
if (($MIME_type =~ m/$set->{'mime'}/) and
($Magic =~ m/$set->{'magic'}/s)) { # found the method to use
to
if (($MIME_type =~ m/$set->{'mime'}/i) and
($Magic =~ m/$set->{'magic'}/s)) { # found the method to use
And the same in try_text.
I will be releasing a new version of doc2html very soon, I hope these are
the last changes I have to make!
--
David Adams
Computing Services
Southampton University
----- Original Message -----
From: "Abell, Martin" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, May 23, 2001 9:55 PM
Subject: [htdig] doc2html not picking up wp2html output
> If I try to convert a Wordperfect document using doc2html I get:
>
> doc2html: barf.html CANNOT DO: (application/wordperfect5.1) is apparently
> binary
>
> If I enter the command string that doc2html generates ...
> /usr/local/bin/wp2html/wp2html -q -DTitle="[barf.html]" -c doc2html.cfg -s
> doc2html.sty -i '/web/html/labsup/pub/custody.wpd' -O;
> ... wp2html spits the converted document to my screen.
>
> I think the mime type is OK (what I expect from our server) and I even
> checked the magic number of the document and it is OK. So I'm not sure
what
> is wrong. (But doc2html seems not to get beyond the "while (<CAT>) {"
line
> in subroutine try_html.)
>
> Anyone got any thoughts?
>
> Martin Abell.
>
> _______________________________________________
> htdig-general mailing list <[EMAIL PROTECTED]>
> To unsubscribe, send a message to
<[EMAIL PROTECTED]> with a subject of unsubscribe
> FAQ: http://htdig.sourceforge.net/FAQ.html
>
_______________________________________________
htdig-general mailing list <[EMAIL PROTECTED]>
To unsubscribe, send a message to <[EMAIL PROTECTED]> with a
subject of unsubscribe
FAQ: http://htdig.sourceforge.net/FAQ.html