[21784] in Perl-Users-Digest
Perl-Users Digest, Issue: 3988 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Oct 17 11:11:46 2002
Date: Thu, 17 Oct 2002 08:10:17 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Thu, 17 Oct 2002 Volume: 10 Number: 3988
Today's topics:
Re: Problems with perl.org/perlmongers.org websites and <comdog@panix.com>
Re: Random Character Picker <bernard.el-hagin@DODGE_THISlido-tech.net>
Re: Random Character Picker <spam@stinks.com>
Re: Random Character Picker <spam@stinks.com>
Re: Random Character Picker <bernard.el-hagin@DODGE_THISlido-tech.net>
Re: Read a single character from STDIN (W98) <nikogo@nigde.net>
Re: regular expressions... really don't get it! (Tad McClellan)
Re: Sending argument to perl (Me)
Re: Sending argument to perl (Tad McClellan)
Sending email with blat.exe through a Perlscript <asmith2@rational.com>
Re: Sending email with blat.exe through a Perlscript <digiover@dsinet.org>
Where can I learn about Perl & ActiveX and OLE <uzshaf@uni-bonn.de>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Thu, 17 Oct 2002 08:48:28 -0500
From: brian d foy <comdog@panix.com>
Subject: Re: Problems with perl.org/perlmongers.org websites and email addresses
Message-Id: <171020020848281643%comdog@panix.com>
In article <kaosqu0f53gcn5ifh1usv6ucv7krbuo8hj@4ax.com>, Bart Lateur <bart.lateur@pandora.be> wrote:
> brian d foy wrote:
>
> >> The website <http://lists.perl.org> is offline, gining me a 500 "could
> >> not connect to server" error. I tried to warn the webmaster via
> >> <lists@perlmongers.org> but my SMTP server refuses to send mail to that
> >> address:
> >
> >why are you using that domain?
>
> See this page, reachable from the link "contact us" on
> <http://www.perl.org>
ah, okay. that page is wrong.
>i think Elaine Ashton was the one taking care of lists.perl.org.
> So how am I supposed to know that, if there's nothing mentioned on the
> home page?
which home page? the various sub domains are run by different people.
just because they are all perl.org doesn't mean one person is responsible
for all of them. it's a community thing.
you know it because I told you, or because you ask "Who should I ask about this?". :)
--
brian d foy <comdog@panix.com> - Perl services for hire
The Perl Review - a new magazine devoted to Perl
<http://www.theperlreview.com>
------------------------------
Date: Thu, 17 Oct 2002 13:23:28 +0000 (UTC)
From: Bernard El-Hagin <bernard.el-hagin@DODGE_THISlido-tech.net>
Subject: Re: Random Character Picker
Message-Id: <aomdkg$6v2$3@korweta.task.gda.pl>
In article <LTxr9.831$XsJ4.25034938@news2.randori.com>, PinkPuppy
wrote:
> Here's what I ended up doing. It's simpler than some of the excellent
> suggestions, but it works...
>
> my @c = ("a","b","c","d","e","f","g","h","i","j","k",
> "l","m","n","o","p","q","r","s","t","u","v","w","x",
> "y","z","A","B","C","D","E","F","G","H","I","J",
> "K","L","M","N","O","P","Q","R","S","T","U","V",
> "W","X","Y","Z","0","1","2","3","4","5","6","7","8","9" );
If you're gonna do it that way why not make it easier on the eyes:
my @c = ('a' .. 'z', 'A' .. 'Z', 0 .. 9);
Cheers,
Bernard
--
echo 42|perl -pe '$#="Just another Perl hacker,"'
------------------------------
Date: Thu, 17 Oct 2002 13:49:18 GMT
From: "PinkPuppy" <spam@stinks.com>
Subject: Re: Random Character Picker
Message-Id: <ydzr9.838$XsJ4.45285428@news2.randori.com>
"Bernard El-Hagin" <bernard.el-hagin@DODGE_THISlido-tech.net> wrote in
message news:aomdkg$6v2$3@korweta.task.gda.pl...
> In article <LTxr9.831$XsJ4.25034938@news2.randori.com>, PinkPuppy
> wrote:
> > Here's what I ended up doing. It's simpler than some of the excellent
> > suggestions, but it works...
> >
> > my @c = ("a","b","c","d","e","f","g","h","i","j","k",
> > "l","m","n","o","p","q","r","s","t","u","v","w","x",
> > "y","z","A","B","C","D","E","F","G","H","I","J",
> > "K","L","M","N","O","P","Q","R","S","T","U","V",
> > "W","X","Y","Z","0","1","2","3","4","5","6","7","8","9" );
>
>
> If you're gonna do it that way why not make it easier on the eyes:
>
>
> my @c = ('a' .. 'z', 'A' .. 'Z', 0 .. 9);
>
>
> Cheers,
> Bernard
> --
> echo 42|perl -pe '$#="Just another Perl hacker,"'
Thanks, I didn't know you could do that.
------------------------------
Date: Thu, 17 Oct 2002 13:50:41 GMT
From: "PinkPuppy" <spam@stinks.com>
Subject: Re: Random Character Picker
Message-Id: <Rezr9.839$XsJ4.45023398@news2.randori.com>
"Bernard El-Hagin" <bernard.el-hagin@DODGE_THISlido-tech.net> wrote in
message news:aomdkg$6v2$3@korweta.task.gda.pl...
> In article <LTxr9.831$XsJ4.25034938@news2.randori.com>, PinkPuppy
> wrote:
> > Here's what I ended up doing. It's simpler than some of the excellent
> > suggestions, but it works...
> >
> > my @c = ("a","b","c","d","e","f","g","h","i","j","k",
> > "l","m","n","o","p","q","r","s","t","u","v","w","x",
> > "y","z","A","B","C","D","E","F","G","H","I","J",
> > "K","L","M","N","O","P","Q","R","S","T","U","V",
> > "W","X","Y","Z","0","1","2","3","4","5","6","7","8","9" );
>
>
> If you're gonna do it that way why not make it easier on the eyes:
>
>
> my @c = ('a' .. 'z', 'A' .. 'Z', 0 .. 9);
>
>
> Cheers,
> Bernard
> --
> echo 42|perl -pe '$#="Just another Perl hacker,"'
>
Well, now that I look at it I can't do that, but perhaps some variation of
that. I have since removed certain characters from the array such as "l",
"q", and "0", so it makes using the ".." notation a bit trickier.
------------------------------
Date: Thu, 17 Oct 2002 13:55:38 +0000 (UTC)
From: Bernard El-Hagin <bernard.el-hagin@DODGE_THISlido-tech.net>
Subject: Re: Random Character Picker
Message-Id: <slrnaqtg7c.15m.bernard.el-hagin@gdndev25.lido-tech>
In article <Rezr9.839$XsJ4.45023398@news2.randori.com>, PinkPuppy
wrote:
> "Bernard El-Hagin" <bernard.el-hagin@DODGE_THISlido-tech.net> wrote in
> message news:aomdkg$6v2$3@korweta.task.gda.pl...
>> In article <LTxr9.831$XsJ4.25034938@news2.randori.com>, PinkPuppy
>> wrote:
>> > Here's what I ended up doing. It's simpler than some of the excellent
>> > suggestions, but it works...
>> >
>> > my @c = ("a","b","c","d","e","f","g","h","i","j","k",
>> > "l","m","n","o","p","q","r","s","t","u","v","w","x",
>> > "y","z","A","B","C","D","E","F","G","H","I","J",
>> > "K","L","M","N","O","P","Q","R","S","T","U","V",
>> > "W","X","Y","Z","0","1","2","3","4","5","6","7","8","9" );
>>
>>
>> If you're gonna do it that way why not make it easier on the eyes:
>>
>>
>> my @c = ('a' .. 'z', 'A' .. 'Z', 0 .. 9);
>>
>
> Well, now that I look at it I can't do that, but perhaps some variation of
> that. I have since removed certain characters from the array such as "l",
> "q", and "0", so it makes using the ".." notation a bit trickier.
You can skip stuff from the lists like this:
my @c = ('a' .. 'k', 'm' .. 'z'); # skips 'l'
Cheers,
Bernard
--
echo 42|perl -pe '$#="Just another Perl hacker,"'
------------------------------
Date: Thu, 17 Oct 2002 13:56:48 GMT
From: "Nemo Oudeheis" <nikogo@nigde.net>
Subject: Re: Read a single character from STDIN (W98)
Message-Id: <Akzr9.9721$1P1.767443@bgtnsc05-news.ops.worldnet.att.net>
#SOLUTION: (just to pull it to the top of the thread where it can
be seen)
# --------------------------------------
use strict;
use warnings;
use Win32::Console;
my $console = Win32::Console->new(STD_INPUT_HANDLE);
my $oldMode = $console->Mode();
$console->Mode( ~(ENABLE_LINE_INPUT|ENABLE_ECHO_INPUT) & $oldMode );
print "Y/N?";
my $c = $console->InputChar(1);
printf( "\nYou typed \"%s\" (i.e., 0x%0x)\n", $c, ord $c );
$console->Mode( $oldMode );
# --------------------------------------
Thanks to Benjamin Goldberg.
Nemo Oudeheis <nikogo@nigde.net> wrote in message
news:tyCq9.21548$ue4.1422094@bgtnsc04-news.ops.worldnet.att.net...
> I am using ActivePerl on a Win98 system. I would like to read a single
> character from STDIN to get the reply from a (Y/N) question, without
having
> to terminate the line with by hitting <ENTER>, as is the default with getc
> and read.
>
> The example given in the ActivePerl documentation says to use stty and
> $BSD_STYLE, but these are not available on a Windows system, as far as I
> know.
>
> Probably I have to slurp the character at a lower level than the STDIN
> buffer, no?
>
> Thanks for the help.
>
>
> ~Nemo
>
>
------------------------------
Date: Thu, 17 Oct 2002 06:57:59 -0500
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: regular expressions... really don't get it!
Message-Id: <slrnaqt9e7.284.tadmc@magna.augustmail.com>
Evert <linux@dds.nl> wrote:
> so that is where the perl documentation is hidden!!
> if i knew that
> before......
http://mail.augustmail.com/~tadmc/clpmisc.shtml
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: 17 Oct 2002 06:23:27 -0700
From: fnardone@hotmail.com (Me)
Subject: Re: Sending argument to perl
Message-Id: <ce36f152.0210170523.79346996@posting.google.com>
Bernard El-Hagin <bernard.el-hagin@DODGE_THISlido-tech.net> wrote in message news:<slrnaqslnv.12b.bernard.el-hagin@gdndev25.lido-tech>...
> In article <3dae5475_2@nopics.sjc>, cakes99 wrote:
> > How would I go about sending arguments to perl using the shell command.
> >
> > For instance: perl somescript.pl argument
> >
> > Perl takes the argument as a file.
>
>
> No it doesn't.
Perl does not but the shell may do.
e.g. (using print @ARGV)
% perl.pl pe*
% perl.plpear.txt
The thing to do is to quote your arguments:
% perl.pl 'pe*'
% pe*
>
>
> > Is it possible to pass the argument to
> > the script in a line command without it being passed as a file???
>
>
> % cat perl.pl
> print @ARGV;
>
> % perl perl.pl aaa bbb
> aaabbb
>
>
> Cheers,
> Bernard
------------------------------
Date: Thu, 17 Oct 2002 08:16:49 -0500
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: Sending argument to perl
Message-Id: <slrnaqte21.284.tadmc@magna.augustmail.com>
cakes99 <cakes@doentreply.com> wrote:
> How would I go about sending arguments to perl using the shell command.
The same way you would go about sending arguments to any
other program using the shell.
> For instance: perl somescript.pl argument
That _is_ how you send arguments to perl using the shell.
> Perl takes the argument as a file.
No it doesn't.
The diamond operator ( <> ) might do that though. Does your
program use the diamond operator?
> Is it possible to pass the argument to
> the script in a line command without it being passed as a file???
Yes.
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Thu, 17 Oct 2002 09:08:39 -0400
From: "Smith, Aaron" <asmith2@rational.com>
Subject: Sending email with blat.exe through a Perlscript
Message-Id: <657B3BF8C9B17249A8E3BF98622AE88D0AFEE3FB@sus-ma1it06.rational.com>
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
------_=_NextPart_001_01C275DE.4F877C64
Content-Type: text/plain;
charset="iso-8859-1"
Try $blatpath = "C:\\WINNT\\system32\\blat.exe ";
-----Original Message-----
From: J. Reilink [mailto:digiover@dsinet.org]
Posted At: Thursday, October 17, 2002 7:14 AM
Posted To: comp.lang.perl.misc
Conversation: Sending email with blat.exe through a Perlscript
Subject: Sending email with blat.exe through a Perlscript
I hope this is not OT.
I have read the previous thread about blat.exe and Perl but unfortunaly
the solution I am looking for is not there.
I am trying to let a .pl script send email by using Blat.exe (version
1.8.9), but (obviously) I am not successful.
The script I am trying to use is a c'n'p from the RoadRunner supportpage
(http://www.rrpro.com/support/webform_blat.asp) with a few
modifications.
If you run the script you get a nice HTML output but the mail doesn't
get send. However, when I c'n'p the output to the commandline on Win2K,
the email does get send away...
I think the problem lies here, but I am not sure:
# Get message ready #
$commandline = $blatpath;
$commandline .= $message;
$commandline .= "-subject \"$subject\" " if $subject;
$commandline .= "-to $recipients " if $recipients;
$commandline .= "-f $fromsender " if $fromsender;
$commandline .= "-cc $ccaddress " if $ccaddress;
$commandline .= "-server $server " if $server;
print "\$commandline \= $commandline";
print "<P>\n";
print "<P>\n";
print "<P>\n";
# Send mail using blat and the system command #
$status = system($commandline);
print "<P>\n";
print "<P>\n";
print "Blat has been executed (status = $status). <P>\n";
(complete script in my signature).
status = $status gives me a 512-code, which (devided by 256) is return
code 2[1]. According to
www.geocities.com/toby_korn/blat/blat_return_codes.htm this means that
the file (testblat.txt) isn't found, but it is there with IUSR read
rights.
I have tried different PATH's, I have changed the line
$commandline .= "-t $recipients " if $recipients; to
$commandline .= "-to $recipients " if $recipients; , the "-to" switch is
in the blat commandline options, but I am still not sucessful.
Strangest thing (as stated above) when I copy $commandline to CMD, the
email is send out and I receive it on $recipients.
Also, by typing "type blat.pl | perl.exe" on CMD the email gets send, so
probably the script is ok?!
Information:
C:\>perl -v
This is perl, v5.6.1 built for MSWin32-x86-multi-thread
(with 1 registered patch, see perl -V for more detail)
C:\>perl -V
Summary of my perl5 (revision 5 version 6 subversion 1) configuration:
Platform:
osname=MSWin32, osvers=4.0, archname=MSWin32-x86-multi-thread
[snip]
C:\>blat
Blat v1.8.9: WinNT/95 console utility to mail a file via SMTP
by P.Mendes, M.Neal, G.Vollant, T. Charron
http://www.blat.net
Thanks in advance for any pointers/help, I just started with Perl.
If this message is OT here, please direct me to the proper newsgroup(s)
and/or set an follow up.
[1]
http://groups.google.com/groups?hl=nl&lr=&ie=UTF-8&oe=UTF-8&frame=right&
th=53a0646055437b2d&seekm=356eb2da.9389978%40news.btinternet.com#link1
Regards, Jan
--
/"\ ASCII Ribbon Campaign
\ / No HTML in mail or news!
X Vevida Services: http://www.vevida.nl /
janreilink@vevida.nl
/ \ DSINet: http://www.dsinet.org / digiover@dsinet.org
-- blat.pl
# Standard BLAT Script
# define your variables and name blat.pl
#
# This script is an example of a script that will work with BLAT
# to send messages via PERL on the Road Runner Commerical
# Web Hosting Server. A more Parctical application is to feed in
# the variables from a form page.
#
## Define variables ##
# Send to...
$recipients = "digiover\@dsinet.org";
# Note the use of the "\" character, used to escape special characters
# CC Address, remove "#" if you plan to use...
# $ccaddress = "foo\@bar.com";
# From Address - MUST be a valid e-mail address
$fromsender = "janreilink\@vevida.nl";
# E-mail Subject Line...
$subject = "sending testblat.txt 18";
# The message must be a file that will be included
# in the body of the message. You can't pipe a message.
# This message does exist and can be used for testing
$message = "D:\\www\dsinet.be\\www\\blat\\testblat.txt ";
##########################
# Blat path DON'T CHANGE.
$blatpath = "C:\\WINNT\\system32\\blat ";
##########################
# print an html-complient execution confirmation page #
print "Content-Type: text/html\n\n"; # add header for HTML document
print "<html>\n";
print "<head><title> $input{'type'} Search Results </title></head>\n";
print "<body BACKGROUND=\"images/tile.gif\">\n";
print "<hr>\n";
print "An E-mail message is about to be sent by blat.exe\:\n";
print "<PRE><P>\n";
print "To\: $recipients \n";
print "Subject\: $subject \n";
print "File\: $message \n";
# print "Server\: $server \n";
print "<P>\n";
print "</PRE><P>\n";
# Get message ready #
$commandline = $blatpath;
$commandline .= $message;
$commandline .= "-subject \"$subject\" " if $subject;
$commandline .= "-to $recipients " if $recipients;
$commandline .= "-f $fromsender " if $fromsender;
$commandline .= "-cc $ccaddress " if $ccaddress;
$commandline .= "-server $server " if $server;
print "\$commandline \= $commandline";
print "<P>\n";
print "<P>\n";
print "<P>\n";
# Send mail using blat and the system command #
$status = system($commandline);
print "<P>\n";
print "<P>\n";
print "Blat has been executed (status = $status). <P>\n";
# Finish printing html-compliant execution confirmation page #
print "<P>\n";
print "<P>\n";
print "<P>\n";
print "</body>\n";
print "</HTML>\n";
------_=_NextPart_001_01C275DE.4F877C64
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3Diso-8859-1">
<META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version =
5.5.2654.19">
<TITLE></TITLE>
</HEAD>
<BODY>
<P><FONT SIZE=3D2>Try $blatpath =3D "C:\\WINNT\\system32\\blat.exe =
";</FONT>
</P>
<P><FONT SIZE=3D2>-----Original Message-----</FONT>
<BR><FONT SIZE=3D2>From: J. Reilink [<A =
HREF=3D"mailto:digiover@dsinet.org">mailto:digiover@dsinet.org</A>]</FON=
T>
<BR><FONT SIZE=3D2>Posted At: Thursday, October 17, 2002 7:14 AM</FONT>
<BR><FONT SIZE=3D2>Posted To: comp.lang.perl.misc</FONT>
<BR><FONT SIZE=3D2>Conversation: Sending email with blat.exe through a =
Perlscript</FONT>
<BR><FONT SIZE=3D2>Subject: Sending email with blat.exe through a =
Perlscript</FONT>
</P>
<BR>
<P><FONT SIZE=3D2>I hope this is not OT.</FONT>
<BR><FONT SIZE=3D2>I have read the previous thread about blat.exe and =
Perl but unfortunaly </FONT>
<BR><FONT SIZE=3D2>the solution I am looking for is not there.</FONT>
</P>
<P><FONT SIZE=3D2>I am trying to let a .pl script send email by using =
Blat.exe (version </FONT>
<BR><FONT SIZE=3D2>1.8.9), but (obviously) I am not successful.</FONT>
<BR><FONT SIZE=3D2>The script I am trying to use is a c'n'p from the =
RoadRunner supportpage </FONT>
<BR><FONT SIZE=3D2>(<A =
HREF=3D"http://www.rrpro.com/support/webform_blat.asp" =
TARGET=3D"_blank">http://www.rrpro.com/support/webform_blat.asp</A>) =
with a few modifications.</FONT>
</P>
<P><FONT SIZE=3D2>If you run the script you get a nice HTML output but =
the mail doesn't </FONT>
<BR><FONT SIZE=3D2>get send. However, when I c'n'p the output to the =
commandline on Win2K, </FONT>
<BR><FONT SIZE=3D2>the email does get send away...</FONT>
</P>
<P><FONT SIZE=3D2>I think the problem lies here, but I am not =
sure:</FONT>
<BR> <FONT SIZE=3D2># Get =
message ready #</FONT>
<BR> <FONT =
SIZE=3D2>$commandline =3D $blatpath;</FONT>
<BR> <FONT =
SIZE=3D2>$commandline .=3D $message;</FONT>
<BR> <FONT =
SIZE=3D2>$commandline .=3D "-subject \"$subject\" " =
if $subject;</FONT>
<BR> <FONT =
SIZE=3D2>$commandline .=3D "-to $recipients " if =
$recipients;</FONT>
<BR> <FONT =
SIZE=3D2>$commandline .=3D "-f $fromsender " if =
$fromsender;</FONT>
<BR> <FONT =
SIZE=3D2>$commandline .=3D "-cc $ccaddress " if =
$ccaddress;</FONT>
<BR> <FONT =
SIZE=3D2>$commandline .=3D "-server $server " if =
$server;</FONT>
</P>
<P> <FONT SIZE=3D2>print =
"\$commandline \=3D $commandline";</FONT>
<BR> <FONT SIZE=3D2>print =
"<P>\n";</FONT>
<BR> <FONT SIZE=3D2>print =
"<P>\n";</FONT>
<BR> <FONT SIZE=3D2>print =
"<P>\n";</FONT>
</P>
<P> <FONT SIZE=3D2># Send =
mail using blat and the system command #</FONT>
<BR> <FONT SIZE=3D2>$status =
=3D system($commandline);</FONT>
<BR> <FONT SIZE=3D2>print =
"<P>\n";</FONT>
<BR> <FONT SIZE=3D2>print =
"<P>\n";</FONT>
<BR> <FONT SIZE=3D2>print =
"Blat has been executed (status =3D $status). =
<P>\n";</FONT>
<BR><FONT SIZE=3D2>(complete script in my signature).</FONT>
</P>
<P><FONT SIZE=3D2>status =3D $status gives me a 512-code, which =
(devided by 256) is return </FONT>
<BR><FONT SIZE=3D2>code 2[1]. According to </FONT>
<BR><FONT =
SIZE=3D2>www.geocities.com/toby_korn/blat/blat_return_codes.htm this =
means that </FONT>
<BR><FONT SIZE=3D2>the file (testblat.txt) isn't found, but it is there =
with IUSR read rights.</FONT>
</P>
<P><FONT SIZE=3D2>I have tried different PATH's, I have changed the =
line</FONT>
<BR><FONT SIZE=3D2>$commandline .=3D "-t $recipients " if =
$recipients; to</FONT>
<BR><FONT SIZE=3D2>$commandline .=3D "-to $recipients " if =
$recipients; , the "-to" switch is </FONT>
<BR><FONT SIZE=3D2>in the blat commandline options, but I am still not =
sucessful.</FONT>
</P>
<P><FONT SIZE=3D2>Strangest thing (as stated above) when I copy =
$commandline to CMD, the </FONT>
<BR><FONT SIZE=3D2>email is send out and I receive it on =
$recipients.</FONT>
<BR><FONT SIZE=3D2>Also, by typing "type blat.pl | perl.exe" =
on CMD the email gets send, so </FONT>
<BR><FONT SIZE=3D2>probably the script is ok?!</FONT>
</P>
<P><FONT SIZE=3D2>Information:</FONT>
<BR><FONT SIZE=3D2>C:\>perl -v</FONT>
</P>
<P><FONT SIZE=3D2>This is perl, v5.6.1 built for =
MSWin32-x86-multi-thread</FONT>
<BR><FONT SIZE=3D2>(with 1 registered patch, see perl -V for more =
detail)</FONT>
</P>
<P><FONT SIZE=3D2>C:\>perl -V</FONT>
<BR><FONT SIZE=3D2>Summary of my perl5 (revision 5 version 6 subversion =
1) configuration:</FONT>
<BR><FONT SIZE=3D2> Platform:</FONT>
<BR><FONT SIZE=3D2> osname=3DMSWin32, =
osvers=3D4.0, archname=3DMSWin32-x86-multi-thread</FONT>
<BR><FONT SIZE=3D2>[snip]</FONT>
</P>
<P><FONT SIZE=3D2>C:\>blat</FONT>
<BR><FONT SIZE=3D2>Blat v1.8.9: WinNT/95 console utility to mail a file =
via SMTP</FONT>
<BR><FONT SIZE=3D2>by P.Mendes, M.Neal, G.Vollant, T. Charron</FONT>
<BR><FONT SIZE=3D2> <A HREF=3D"http://www.blat.net" =
TARGET=3D"_blank">http://www.blat.net</A></FONT>
</P>
<P><FONT SIZE=3D2>Thanks in advance for any pointers/help, I just =
started with Perl.</FONT>
<BR><FONT SIZE=3D2>If this message is OT here, please direct me to the =
proper newsgroup(s) </FONT>
<BR><FONT SIZE=3D2>and/or set an follow up.</FONT>
</P>
<P><FONT SIZE=3D2>[1] </FONT>
<BR><FONT SIZE=3D2><A =
HREF=3D"http://groups.google.com/groups?hl=3Dnl&lr=3D&ie=3DUTF-8&oe=3DUT=
F-8&frame=3Dright&th=3D53a0646055437b2d&seekm=3D356eb2da.9389978%40news.=
btinternet.com#link1" =
TARGET=3D"_blank">http://groups.google.com/groups?hl=3Dnl&lr=3D&ie=3DUTF=
-8&oe=3DUTF-8&frame=3Dright&th=3D53a0646055437b2d&seekm=3D356eb2da.93899=
78%40news.btinternet.com#link1</A></FONT></P>
<P><FONT SIZE=3D2>Regards, Jan</FONT>
</P>
<P><FONT SIZE=3D2>-- </FONT>
<BR><FONT SIZE=3D2>/"\ ASCII Ribbon Campaign</FONT>
<BR><FONT SIZE=3D2>\ / No HTML in mail or news!</FONT>
<BR><FONT SIZE=3D2> =
X Vevida =
Services: <A HREF=3D"http://www.vevida.nl" =
TARGET=3D"_blank">http://www.vevida.nl</A> / =
janreilink@vevida.nl</FONT>
<BR><FONT SIZE=3D2>/ \ =
DSINet: <A HREF=3D"http://www.dsinet.org" =
TARGET=3D"_blank">http://www.dsinet.org</A> / =
digiover@dsinet.org</FONT>
</P>
<P><FONT SIZE=3D2>-- blat.pl</FONT>
</P>
<P><FONT SIZE=3D2># Standard BLAT Script</FONT>
<BR><FONT SIZE=3D2># define your variables and name blat.pl</FONT>
<BR><FONT SIZE=3D2>#</FONT>
<BR><FONT SIZE=3D2># This script is an example of a script that will =
work with BLAT</FONT>
<BR><FONT SIZE=3D2># to send messages via PERL on the Road Runner =
Commerical</FONT>
<BR><FONT SIZE=3D2># Web Hosting Server. A more Parctical application =
is to feed in</FONT>
<BR><FONT SIZE=3D2># the variables from a form page.</FONT>
<BR><FONT SIZE=3D2>#</FONT>
<BR><FONT SIZE=3D2>## Define variables =
##</FONT>
</P>
<P><FONT SIZE=3D2># Send to...</FONT>
<BR><FONT SIZE=3D2>$recipients =3D =
"digiover\@dsinet.org";</FONT>
<BR><FONT SIZE=3D2># Note the use of the "\" character, used =
to escape special characters</FONT>
</P>
<P><FONT SIZE=3D2># CC Address, remove "#" if you plan to =
use...</FONT>
<BR><FONT SIZE=3D2># $ccaddress =3D "foo\@bar.com";</FONT>
</P>
<P><FONT SIZE=3D2># From Address - MUST be a valid e-mail =
address</FONT>
<BR><FONT SIZE=3D2>$fromsender =3D =
"janreilink\@vevida.nl";</FONT>
</P>
<P><FONT SIZE=3D2># E-mail Subject Line...</FONT>
<BR><FONT SIZE=3D2>$subject =3D "sending testblat.txt =
18";</FONT>
</P>
<P><FONT SIZE=3D2># The message must be a file that will be =
included</FONT>
<BR><FONT SIZE=3D2># in the body of the message. You can't pipe a =
message.</FONT>
<BR><FONT SIZE=3D2># This message does exist and can be used for =
testing</FONT>
<BR><FONT SIZE=3D2>$message =3D =
"D:\\www\dsinet.be\\www\\blat\\testblat.txt ";</FONT>
</P>
<P><FONT SIZE=3D2>##########################</FONT>
<BR><FONT SIZE=3D2># Blat path DON'T CHANGE.</FONT>
<BR><FONT SIZE=3D2>$blatpath =3D "C:\\WINNT\\system32\\blat =
";</FONT>
<BR><FONT SIZE=3D2>##########################</FONT>
</P>
<P><FONT SIZE=3D2># print an html-complient execution confirmation page =
#</FONT>
</P>
<P><FONT SIZE=3D2>print "Content-Type: text/html\n\n"; # add =
header for HTML document</FONT>
<BR><FONT SIZE=3D2>print "<html>\n";</FONT>
<BR><FONT SIZE=3D2>print "<head><title> $input{'type'} =
Search Results </title></head>\n";</FONT>
<BR><FONT SIZE=3D2>print "<body =
BACKGROUND=3D\"images/tile.gif\">\n";</FONT>
<BR><FONT SIZE=3D2>print "<hr>\n";</FONT>
</P>
<P><FONT SIZE=3D2>print "An E-mail message is about to be sent by =
blat.exe\:\n";</FONT>
<BR><FONT SIZE=3D2>print "<PRE><P>\n";</FONT>
<BR><FONT SIZE=3D2>print "To\: $recipients \n";</FONT>
<BR><FONT SIZE=3D2>print "Subject\: $subject \n";</FONT>
<BR><FONT SIZE=3D2>print "File\: $message \n";</FONT>
<BR><FONT SIZE=3D2># print "Server\: $server \n";</FONT>
<BR><FONT SIZE=3D2>print "<P>\n";</FONT>
<BR><FONT SIZE=3D2>print "</PRE><P>\n";</FONT>
</P>
<P><FONT SIZE=3D2># Get message ready #</FONT>
</P>
<P><FONT SIZE=3D2>$commandline =3D $blatpath;</FONT>
<BR><FONT SIZE=3D2>$commandline .=3D $message;</FONT>
<BR><FONT SIZE=3D2>$commandline .=3D "-subject =
\"$subject\" " if $subject;</FONT>
<BR><FONT SIZE=3D2>$commandline .=3D "-to $recipients " if =
$recipients;</FONT>
<BR><FONT SIZE=3D2>$commandline .=3D "-f $fromsender " if =
$fromsender;</FONT>
<BR><FONT SIZE=3D2>$commandline .=3D "-cc $ccaddress " if =
$ccaddress;</FONT>
<BR><FONT SIZE=3D2>$commandline .=3D "-server $server " if =
$server;</FONT>
</P>
<P><FONT SIZE=3D2>print "\$commandline \=3D =
$commandline";</FONT>
<BR><FONT SIZE=3D2>print "<P>\n";</FONT>
<BR><FONT SIZE=3D2>print "<P>\n";</FONT>
<BR><FONT SIZE=3D2>print "<P>\n";</FONT>
</P>
<P><FONT SIZE=3D2># Send mail using blat and the system command =
#</FONT>
</P>
<P><FONT SIZE=3D2>$status =3D system($commandline);</FONT>
<BR><FONT SIZE=3D2>print "<P>\n";</FONT>
<BR><FONT SIZE=3D2>print "<P>\n";</FONT>
<BR><FONT SIZE=3D2>print "Blat has been executed (status =3D =
$status). <P>\n";</FONT>
</P>
<P><FONT SIZE=3D2># Finish printing html-compliant execution =
confirmation page #</FONT>
</P>
<P><FONT SIZE=3D2>print "<P>\n";</FONT>
<BR><FONT SIZE=3D2>print "<P>\n";</FONT>
<BR><FONT SIZE=3D2>print "<P>\n";</FONT>
<BR><FONT SIZE=3D2>print "</body>\n";</FONT>
<BR><FONT SIZE=3D2>print "</HTML>\n";</FONT>
</P>
</BODY>
</HTML>
------_=_NextPart_001_01C275DE.4F877C64--
------------------------------
Date: Thu, 17 Oct 2002 15:42:41 +0200
From: "J. Reilink" <digiover@dsinet.org>
Subject: Re: Sending email with blat.exe through a Perlscript
Message-Id: <3DAEBE51.2030007@dsinet.org>
Smith, Aaron wrote:
> Try $blatpath = "C:\\WINNT\\system32\\blat.exe ";
>
I've tried many different things. Among those even the ".exe" in $blatpath.
The error code 2 ($status) basicly says it can't find "testblat.txt", I
think the problem is somewhere there (or in $commandline).
Blat.pl gives, after execution, the follwing HTML output:
An E-mail message is about to be sent by blat.exe:
To: digiover@dsinet.org
Subject: sending testblat.txt 20
File: D:\www\dsinet.be\www\blat\testblat.txt
$commandline = C:\WINNT\system32\blat.exe
D:\www\dsinet.be\www\blat\testblat.txt -subject "sending
testblat.txt 20" -to digiover@dsinet.org -f janreilink@vevida.nl
Blat has been executed (status = 512).
Blat.pl is also in D:\www\dsinet.be\www\blat\
Regards, Jan
--
/"\ ASCII Ribbon Campaign
\ / No HTML in mail or news!
X Vevida Services: http://www.vevida.nl
/ \ DSINet: http://www.dsinet.org
------------------------------
Date: Thu, 17 Oct 2002 16:52:44 +0200
From: "Christian Kappler" <uzshaf@uni-bonn.de>
Subject: Where can I learn about Perl & ActiveX and OLE
Message-Id: <aomitb$uuc$1@f1node01.rhrz.uni-bonn.de>
Hello,
I would like to learn some basics about ActiveX and OLE and I would like to
learn how I can use ActiveX and OLE with Perl.
Where can I find tutorials for this (Best on beginners level)?
Thanks!
Regards,
Christian
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.
For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V10 Issue 3988
***************************************