[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date
][Minivend by thread
]
Re: [mv] .PDF files in a MV page
****** message to minivend-users from Hans-Joachim Leidinger <jojo@buchonline.net> ******
Barry Treahy wrote:
> Mike Heins wrote:
> > There might be a problem with this code:
> >
> > [tag op=header]
> > Content-Type: application/pdf
> > [/tag][file content/something.pdf]
> >
> > I am guessing that there will be one byte appended
> > when creating the file with an editor (appended newline).
> > There are ways to strip the appending newline:
> >
> > perl -0777 -pi 'chomp' pages/deliver_pdf.html
> >
>
> You are correct the the embedded tag didn't work as stated. The page fails to load
> after starting Acrobat with 'An error has occurred while trying to use this
> document.' I attempted the perl statement above on the page containting the tags,
> but I do not have chomp installed in my Perl distribution. I checked CPAN and issued
> a search at their site and came up blank.
>
> Barry
If i know right, ´chomp´ is not an extra module. ´Chomp´ is a perl
syntax like ´print´, ´if else ...´etc.
If you use
perl -h
in your console, you get a list of options and you can see the
description for -p and -i. See README-win.txt too. It is similar like
perl -npi.bak -e "s:\r::g" <file-you-edited>
Regards,
Joachim
--
-------------Hans-Joachim Leidinger---------------------
-
To unsubscribe from the list, DO NOT REPLY to this message. Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list