We are displaying documents on the web as PDF files. But
because we want to log when a user views one of these files,
for later evaluation studies, the hypertext link the user
clicks calls up a cgi-script rather than just downloading
the PDF file. This script performs some logging action
before passing on the PDF file to the user's browser, which
it does by preceding the file's contents by "this is of
type application/pdf". Ie. the script looks like:
#!/bin/sh
#Perform some logging
echo Content-type: application/pdf
echo
cat $PATH_INFO
This worked OK using Acrobat Reader 2.1 as a helper
application in Netscape 2.1.
But it no longer works with Acrobat Reader 3.0 as a plug-in
to Netscape. Netscape kicks off the Acrobat Reader, and
displays the message 'Document Done', but the document
doesn't appear in the Netscape window.
I think this is because Acrobat 3.0 expects a file with a
.pdf extension as well as the 'application/pdf', which it
obviously isn't getting in this case.
If I send the contents of the original PDF file with the
application/pdf heading to a temporary file, and then click
on a hypertext link to this temporary file, this works OK,
so I don't think I am corrupting the contents of the PDF
file in any way.
Can anyone see a way round this? Or another way of logging
when a PDF file is viewed? We want to avoid the user having
to 'click' more than once to view a PDF document.
Thanks,
Ann
PS. Apologies for cross-posting to those on more than list.
----------------------------------------------------------
Mrs. Ann Apps.
SuperJournal Project, National Services Group,
Manchester Computing, University of Manchester,
Oxford Road, Manchester, M13 9PL, UK.
Tel: +44 161 275 6039
Fax: +44 161 275 6040
Email: [log in to unmask]
WWW: http://www.superjournal.ac.uk/sj/
----------------------------------------------------------
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|