John,

You can remove the outputfile parameter completely, it really isn't
needed. Now in the perl script just replace the lpr with /dev/ttyS0 and
see if that works. Or you can setup LPR to use your serial printer,
either way.

Thanks,

Derrick

On Aug 6, 2004, at 6:24 AM, John Puzon wrote:

> Derrick,
>
>  Yes it created a file and it was empty.��Just like what i did before.
> The browser displayed the message without errors.��But when i tried
> redirecting the outputfile to /dev/ttyS0, nothing.��When i ran the
> print.pl from the shell it prints: "lpr: error - scheduler not
> responding!"
>
>
>  -John
>
>  >John,
>  >
>  >Try this simple script called print.pl
>  >
>  >!/usr/bin/perl
>  >open(OUTPUT, "| lpr");
>  >print OUTPUT "Hello from Perl.\n";
>  >close OUTPUT
>  >
>  >and create this simple cfm page called testperl.cfm
>  >
>  ><html>
>  ><head>
>  ><title>Test Perl Print page</title>
>  ></head>
>  ><body bgcolor="#ffffff">
>  >This is a test of the print.pl script using cfexecute
>  >
>  ><cfexecute name="/var/www/html/print.pl"
>  >outputfile="/var/www/html/testoutput.txt" timeout="1"></cfexecute>
>  >
>  ><p>Test Should be complete</p>
>  ></body>
>  ></html>
>  >
>  >Now even though it creates a file called testoutput.txt, the file
>  >should be empty. Make sure that you change the path to match your
>  >directory. Now this simple perl file ran without any problems on my
>  >machine. I hope you have similar luck.
>  >
>  >Thanks,
>  >
>  >Derrick
>  >
>  >
>  >
>  >On Aug 5, 2004, at 10:16 PM, John Puzon wrote:
>  >
>  >>
>
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

Reply via email to