[15946] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 3359 Volume: 9

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Jun 14 18:26:19 2000

Date: Wed, 14 Jun 2000 15:26:08 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <961021567-v9-i3359@ruby.oce.orst.edu>
Content-Type: text

Perl-Users Digest           Wed, 14 Jun 2000     Volume: 9 Number: 3359

Today's topics:
    Re: Larry Rosler interview on perl.com! lvirden@cas.org
    Re: Larry Rosler interview on perl.com! lvirden@cas.org
    Re: Larry Rosler interview on perl.com! (Jerome O'Neil)
    Re: Larry Rosler interview on perl.com! <care227@attglobal.net>
    Re: Larry Rosler interview on perl.com! <care227@attglobal.net>
    Re: Larry Rosler interview on perl.com! <dan@tuatha.sidhe.org>
    Re: Larry Rosler interview on perl.com! (Bart Lateur)
    Re: Larry Rosler interview on perl.com! <care227@attglobal.net>
    Re: Larry Rosler interview on perl.com! <lr@hpl.hp.com>
    Re: Larry Rosler interview on perl.com! <dan@tuatha.sidhe.org>
    Re: Length of an Array <abe@ztreet.demon.nl>
    Re: Login and passwords <rootbeer@redcat.com>
    Re: Multi language messages <jeff@vpservices.com>
    Re: Multi language messages (David Wall)
    Re: Multi language messages <iltzu@sci.invalid>
    Re: MySQL problem: $DBI::errstr always null jsunden@my-deja.com
    Re: Need SMTP-Sender for pre-formatted messages (Marc Haber)
        NET::SMTP <tschilbach@aodinc.com>
    Re: NET::SMTP <dan@tuatha.sidhe.org>
    Re: never mind !! (Philip 'Yes, that's my address' Newton)
    Re: never mind !! (Tad McClellan)
    Re: Non echo password (Brandon Metcalf)
    Re: Non echo password <rpearson@quebectel.com>
    Re: Non echo password <billy@arnis-bsl.com>
    Re: Non echo password <dbohl@sgi.com>
        ODBC, MSSQL and Unix <bob@inu.net>
    Re: ODBC, MSSQL and Unix <dwilgaREMOVE@mtholyoke.edu>
        OLE and CGI ?? Not working ! rrubin@rotor.net
        Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: 14 Jun 2000 15:19:24 GMT
From: lvirden@cas.org
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <8i87ps$b2v$1@srv38.cas.org>


According to Drew Simonis  <care227@attglobal.net>:
:> would someone want to spend several years of buracratic rigamarole to get
:> an official 'stamp' confirming that the creator's text book on the workings
:> of perl was in fact the standard?
:
:So that when the Geek Cruise ship sinks and all the implementors drown, 
:there will still be a perl and a Perl?

There won't be any cruises, or for that matter bug fixes or new versions of
perl, if all the people qualified are stuck in comittees trying to construct
formal standards language for perl...
-- 
<URL: https://secure.paypal.com/refer/pal=lvirden%40yahoo.com>
<URL: mailto:lvirden@cas.org> <URL: http://www.purl.org/NET/lvirden/>
Unless explicitly stated to the contrary, nothing in this posting
should be construed as representing my employer's opinions.


------------------------------

Date: 14 Jun 2000 15:21:08 GMT
From: lvirden@cas.org
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <8i87t4$b2v$2@srv38.cas.org>


According to Dan Sugalski  <dan@tuatha.sidhe.org>:
:> :argue for an ANSI standard per se, but a formal definition of the language
:> :would make it less likely that you'd see that.
:> 					  ^^^^
:
:> By 'that', are you referring to 'accidental' changes, or intentional changes?
:
:I was mainly referring to the wobble on undocumented features, and on
:those bits that are only partially or not strictly documened.
:

Then you expect that a standard for perl would document _every_ feature?
-- 
<URL: https://secure.paypal.com/refer/pal=lvirden%40yahoo.com>
<URL: mailto:lvirden@cas.org> <URL: http://www.purl.org/NET/lvirden/>
Unless explicitly stated to the contrary, nothing in this posting
should be construed as representing my employer's opinions.


------------------------------

Date: Wed, 14 Jun 2000 15:33:22 GMT
From: jerome@activeindexing.com (Jerome O'Neil)
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <6BN15.425$li3.12382@news.uswest.net>

Henry <htp@mac.com> elucidates:

> Not to worry, the public beta of Mac OS X (which has a BSD foundation) 
> is coming out sometime within the next 78 days.  The whole issue becomes 
> moot when that happens.

I just returned from the JavaOne conference in San Francisco.  Steve Jobs
was one of the guest speakers, and had a demo of the MacOS X (it is going
to have full Java support, which is why he was there), and I don't
know what it's going to do for Perl, but the GUI rocked.


------------------------------

Date: Wed, 14 Jun 2000 11:37:08 -0400
From: Drew Simonis <care227@attglobal.net>
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <3947A6A4.6DC267E9@attglobal.net>

lvirden@cas.org wrote:
> 
> :I was mainly referring to the wobble on undocumented features, and on
> :those bits that are only partially or not strictly documened.
> :
> 
> Then you expect that a standard for perl would document _every_ feature?
> --


Isn't that kinda the point?


------------------------------

Date: Wed, 14 Jun 2000 12:04:03 -0400
From: Drew Simonis <care227@attglobal.net>
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <3947ACF3.C6859964@attglobal.net>

lvirden@cas.org wrote:
> 
> There won't be any cruises, or for that matter bug fixes or new versions of
> perl, if all the people qualified are stuck in comittees trying to construct
> formal standards language for perl...

I see how standardization has demolished C.


------------------------------

Date: Wed, 14 Jun 2000 16:36:55 GMT
From: Dan Sugalski <dan@tuatha.sidhe.org>
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <HwO15.609$Zg4.3400@news1.rdc1.ct.home.com>

lvirden@cas.org wrote:

> According to Dan Sugalski  <dan@tuatha.sidhe.org>:
> :> :argue for an ANSI standard per se, but a formal definition of the language
> :> :would make it less likely that you'd see that.
> :> 					  ^^^^
> :
> :> By 'that', are you referring to 'accidental' changes, or intentional changes?
> :
> :I was mainly referring to the wobble on undocumented features, and on
> :those bits that are only partially or not strictly documened.
> :

> Then you expect that a standard for perl would document _every_ feature?

Of the core language? Yes. Not necessarily of the core module set, but for
everything that, say, miniperl can do without loading a module. (With the
behaviour of module loading documented too)

I don't much care if 50% of the document is "behaviour in this
curcumstance is undefined", as long as the stuff that *is* defined gets,
well, defined. :)

					Dan


------------------------------

Date: Wed, 14 Jun 2000 16:52:27 GMT
From: bart.lateur@skynet.be (Bart Lateur)
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <3949b833.1113714@news.skynet.be>

Drew Simonis wrote:

>I see how standardization has demolished C.

C was crap already without any help from outside.

-- 
	Bart.


------------------------------

Date: Wed, 14 Jun 2000 13:44:10 -0400
From: Drew Simonis <care227@attglobal.net>
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <3947C46A.6D89FB13@attglobal.net>

Bart Lateur wrote:
> 
> Drew Simonis wrote:
> 
> >I see how standardization has demolished C.
> 
> C was crap already without any help from outside.
> 
> --
>         Bart.


Hey, I was being sarcastic!  I think C is just fine.


------------------------------

Date: Wed, 14 Jun 2000 10:58:10 -0700
From: Larry Rosler <lr@hpl.hp.com>
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <MPG.13b1678b27700fda98ab74@nntp.hpl.hp.com>

In article <HwO15.609$Zg4.3400@news1.rdc1.ct.home.com> on Wed, 14 Jun 
2000 16:36:55 GMT, Dan Sugalski <dan@tuatha.sidhe.org> says...
> lvirden@cas.org wrote:

 ...

> > Then you expect that a standard for perl would document _every_ feature?
> 
> Of the core language? Yes. Not necessarily of the core module set, but for
> everything that, say, miniperl can do without loading a module. (With the
> behaviour of module loading documented too)

The 'core module set' (i.e., those modules that are provided with every 
implementation) seems analogous to the Standard C Library, and could 
well be part of the language definition.  Consider cwd(), to take one 
example among many.
 
> I don't much care if 50% of the document is "behaviour in this
> curcumstance is undefined", as long as the stuff that *is* defined gets,
> well, defined. :)

<pedantic, but this is a field that dotes on pedantry>

    s/defined/specified/g;

Because the ANSI/ISO C Standard isn't available on-line (to my 
knowledge; a matter of copyright protection for the standards 
organizations), I'll transcribe here the definitions of those terms, in 
the hope that they will be enlightening in the Perl context.

    Implementation-defined behavior -- behavior, for a correct program 
construct and correct data, that depends on the characteristics of the 
implementation and that each implementation shall document.

   ...

   Undefined behavior -- behavior, upon use of a nonportable or 
erroneous program construct, of erroneous data, or of indeterminately 
valued objects, for which the standard imposes no requirements.  
Permissible undefined behavior ranges from ignoring the situation 
completely with unpredictable results, to behaving during translation or 
program execution in a documented manner characteristic of the 
environment (with or without the issuance of a diagnostic message), to 
terminating a translation or execution (with the issuance of a 
diagnostic message).

   ...

   Unspecified behavior -- behavior, for a correct program construct and 
correct data, for which the standard explicitly imposes no requirements.

   ...

   An example of unspecified behavior is the order in which the 
arguments to a function are evaluated.

   An example of undefined behavior is the behavior on integer overflow.

   An example of implementation-defined behavior is the propagation of 
the high-order bit when a signed integer is shifted right.

</pedantic>

Note that because of its more abstract computational module, Perl should 
have far fewer implementation-defined behaviors than C.

(Just Another Language Lawyer)

-- 
(Just Another Larry) Rosler
Hewlett-Packard Laboratories
http://www.hpl.hp.com/personal/Larry_Rosler/
lr@hpl.hp.com


------------------------------

Date: Wed, 14 Jun 2000 18:54:00 GMT
From: Dan Sugalski <dan@tuatha.sidhe.org>
Subject: Re: Larry Rosler interview on perl.com!
Message-Id: <cxQ15.732$Zg4.3386@news1.rdc1.ct.home.com>

Larry Rosler <lr@hpl.hp.com> wrote:
> In article <HwO15.609$Zg4.3400@news1.rdc1.ct.home.com> on Wed, 14 Jun 
> 2000 16:36:55 GMT, Dan Sugalski <dan@tuatha.sidhe.org> says...
>> lvirden@cas.org wrote:

> ...

>> > Then you expect that a standard for perl would document _every_ feature?
>> 
>> Of the core language? Yes. Not necessarily of the core module set, but for
>> everything that, say, miniperl can do without loading a module. (With the
>> behaviour of module loading documented too)

> The 'core module set' (i.e., those modules that are provided with every 
> implementation) seems analogous to the Standard C Library, and could 
> well be part of the language definition.  Consider cwd(), to take one 
> example among many.

I'd leave that as a separate project, which seems appropriate. Most of
what I'd equate to C's Standard Library is the stuff documented in
perlfunc, while the modules are more analagous to things like the POSIX
pthread doc, just to pull an example out of the air.

>> I don't much care if 50% of the document is "behaviour in this
>> curcumstance is undefined", as long as the stuff that *is* defined gets,
>> well, defined. :)

<pedantic, but this is a field that dotes on pedantry>

And this is the bit that requires pedantry, that being the whole point. :)

[Snip]

Ah, I was a bit fuzzy on the differences. Thanks for clearing that up.

					Dan


------------------------------

Date: Wed, 14 Jun 2000 22:04:16 +0200
From: Abe Timmerman <abe@ztreet.demon.nl>
Subject: Re: Length of an Array
Message-Id: <klofksont7bmrcmc2o6u060snrgjd8iq4b@4ax.com>

[please quote in context in the future]
On Tue, 13 Jun 2000 16:58:14 -0700, "Godzilla!"
<godzilla@stomp.stomp.tokyo> wrote:

> Abe Timmerman wrote:
>  
> > "Godzilla!" <godzilla@stomp.stomp.tokyo> wrote:
> 
> > Bullshit....
> 
> Has anyone suggested you upgrade your sense
> of humor to meet industry standards? If not,
> I am suggesting this.

Nothing wrong with my sense of humor :)

 ...
> I will ask you to not troll and harass me.
> This unacceptable behavior of yours serves
> no good benefit and disrupts the harmony
> of this newsgroup.
I responded to untrue statements, whether these are from you or anybody
else doesn't make a difference to me. You give yourself to much credit.

-- 
Good luck,
Abe


------------------------------

Date: Wed, 14 Jun 2000 10:11:45 -0700
From: Tom Phoenix <rootbeer@redcat.com>
Subject: Re: Login and passwords
Message-Id: <Pine.GSO.4.10.10006141010390.5301-100000@user2.teleport.com>

On Wed, 14 Jun 2000, vivekvp wrote:

> I want to create a web page that has logins and passwords for multiple
> users.

This is not a Perl issue, but a webserver issue. You may wish to search
for the docs, FAQs, and newsgroups about webservers, and how to set up
yours to do authentication. 

> Anyone aware of a free script that does this - or how to do this?

If you're wishing merely to _find_ (as opposed to write) programs,
this newsgroup may not be the best resource for you. There are many
freeware and shareware archives which you can find by searching Yahoo
or a similar service. Hope this helps!

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/



------------------------------

Date: Wed, 14 Jun 2000 10:54:29 -0700
From: Jeff Zucker <jeff@vpservices.com>
Subject: Re: Multi language messages
Message-Id: <3947C6D5.3EA9B05E@vpservices.com>

Tintin wrote:
> 
> I'm looking for suggestions on the best way to handle error messages in
> multiple languages.
> 
> At the moment, I'm just thinking of creating a file for each language with
> variables set to the appropriate error message, eg:
> 
> English
> $errmsg1='No';
> 
> French
> $errmsg1='Non';
> 
> Is there a much more efficient way of approaching this setup?

I do almost everything in three or more languages so I use simple
textfile databases with DBD::CSV or DBD::RAM.  I have a table with
columns for message number or name, language and value:

       msg | lang | value
       1   | en   | yes
       1   | es   | si
       1   | fr   | oui
       2   | en   | no
       ...

Then, depending on the script, I either get each value with a SELECT
statement as I need it, or I read the whole table into a hash at the top
of the script.  With the hash, I can say things like this to die with
error message number one in French *without needing to invoke a
subroutine*:

    die $errmsg{1}{fr};

Often I use the English as the "msg" column and hash key rather than a
number so I can say things like this to print a message in three
languages:

    for( qw/en es fr/ ) {
        print $errmsg{"You must enter a File Name!"}{$_}, "\n";
    } 

A French programmer might instead use the same table and method but have
the French be the hash key so that their script was more legible to
them.

If your needs are simpler, for example a given script only needs the
French version, not the others, you can make a one dimensional hash when
you load from the database, selecting only the English phrase as the key
and the French phrase as the value, for example and printing the French
error with a simple:

        print $errmsg{"You must enter a File Name!"};

I have code samples of all this if you want them.

-- 
Jeff


------------------------------

Date: 14 Jun 2000 16:22:55 -0400
From: darkon@one.net (David Wall)
Subject: Re: Multi language messages
Message-Id: <8F53AD9B5darkononenet@206.112.192.118>

you.will.always.find.him.in.the.kitchen@parties (Tintin) wrote in 
<960978611.799791@shelley.paradise.net.nz>:

>I'm looking for suggestions on the best way to handle error messages in
>multiple languages.
>
>At the moment, I'm just thinking of creating a file for each language with
>variables set to the appropriate error message, eg:
>
>English
>$errmsg1='No';
>
>French
>$errmsg1='Non';
>
>Is there a much more efficient way of approaching this setup?

Looks like a dictionary.  How about a hash?

my %No_words = ('en'=>'No', 'fr'=>'Non', 'ru'=>'Nyet');

Then you could also have 

my %Yes_words = ('en'=>'Yes', 'fr'=>'Oui', 'ru'=>'Da');

and then maybe do something like

my $Words = { 'Yes'=>\%Yes_words, 'No'=>\%No_words };

so that 

print $Words->{'Yes'}{'fr'};

would print out Yes in French ('Oui').  I don't know how well this will 
scale up for larger applications.  You'd best listen to Alan Flavell and 
the others in this group instead of me.  I suppose you might still want 
some sort of structure like this in a routine that prints out the error 
messages, though.

-- 
David Wall
darkon@one.net


------------------------------

Date: 14 Jun 2000 20:26:08 GMT
From: Ilmari Karonen <iltzu@sci.invalid>
Subject: Re: Multi language messages
Message-Id: <961008606.29069@itz.pp.sci.fi>

In article <960978611.799791@shelley.paradise.net.nz>, Tintin wrote:
>English
>$errmsg1='No';
>
>French
>$errmsg1='Non';

Assuming you don't need to load more than one language per program
invocation, this sounds like a reasonable approach.  You might want to
use functions instead of variables to allow for more complicated
processing, though.

You still need a convenient way to load the appropriate locale files.
TIMTOWTDI, and I'm not claiming the one below to be the best, but it
was kind of fun to write..


File 'myprogram.pl':
  #!/usr/bin/perl -w
  use strict;

  use lib '/usr/lib/myprogram';
  use myLocale;  

  # an example function to demonstrate usage
  sub slurpfile {
      my $file = shift;
      die myLocale::file_not_found($file) unless -e $file;
      open SLURPFILE, $file or die myLocale::open_error($file, $!);
      local $/;
      return <SLURPFILE>;
  }

  # rest of your program goes here..


File '/usr/lib/myprogram/myLocale.pm':
  # -*- perl -*-
  package myLocale;
  use strict;

  my $default = 'EN';
  my $locale = get_the_locale_somehow();

  until (eval "require myLocale::$locale" and !$@) {
      die "Can't load default locale!\n" if $locale eq $default;
      $locale = $default unless $locale =~ s/_[^_]*$//;
  }

  1; # return true to indicate success


File '/usr/lib/myprogram/myLocale/EN.pm':
  # -*-perl-*-
  # note lack of package statement!
  use strict;
 
  sub file_not_found { "File '$_[0]' does not exist.\n" }
  sub open_error { "Error opening '$_[0]': $_[1]\n" }
  sub total_records {
      !$_[0] ? "No records matched!\n"
	  : $_[0] == 1 ? "A unique match was found.\n"
	      : "$_[0] matching records were found.\n";
  }
  # more functions go here

  1; # return true to indicate success


File '/usr/lib/myprogram/myLocale/FI.pm':
  # -*-perl-*-
  # note lack of package statement!
  use strict;
 
  sub file_not_found { "Tiedostoa '$_[0]' ei löydy.\n" }
  sub open_error { "Tiedoston '$_[0]' avaaminen epäonnistui. ($_[1])\n" }
  sub total_records {
      !$_[0] ? "Yksikään tietue ei sopinut ehtoihin!\n"
	  : $_[0] == 1 ? "Yksi tietue sopi ehtoihin.\n"
	      : "$_[0] tietuetta sopi ehtoihin.\n";
  }
  # more functions go here

  1; # return true to indicate success


If you do need multiple locales per invocation, you could perhaps turn
those modules into proper OO classes, with a function in myLocale.pm
to load and instantiate them as needed.  This is left as an exercise.

-- 
Ilmari Karonen - http://www.sci.fi/~iltzu/
Please ignore Godzilla and its pseudonyms - do not feed the troll.



------------------------------

Date: Wed, 14 Jun 2000 16:19:58 GMT
From: jsunden@my-deja.com
Subject: Re: MySQL problem: $DBI::errstr always null
Message-Id: <8i8bao$2v7$1@nnrp1.deja.com>

In article <8gvn43$ltg$1@nnrp1.deja.com>,
  jlamport@calarts.edu wrote:
> In article <8grtp2$4ho$1@nnrp1.deja.com>,
>   jsunden@my-deja.com wrote:
> > Try omitting the $-sign and write DBI->errstr instead. Then it
should
> > work -- it does for me when I use it like this:
> >
> >    $sth->execute or die "Something went wrong: ", DBI->errstr;
> >
> > /Joakim Sundén
>
> Nope.  Attempting to evaluate DBI->errstr causes my program to die
with
>
> "Can't locate auto/DBI/errstr.al in @INC"
>
> Which makes sense to me, since as I understand it, I'm trying to
access a
> variable, not call a function...
>
> Any other suggestions?
>
> -jason
>

Well it has been working for me all the time. When I first learned Perl
my Perl-teacher distributed example code looking just like your code,
that is accessing a variable ("with the dollar-sign"), but when it did
not work he told us to take away the dollar sign, thus calling a
function instead. As I said: it has worked for me ever since. It
assumes you have the "Raise Error" set though (if you call "die" and
not "warn" that is). For example:

my $dsn = "DBI:mysql:database_name:host_name";
my $username = "username";
my $password= "password";
my %attr = ( printError => 1, RaiseError => 1);

$dbh = DBI->connect($dsn, $username, $password, \%attr) || die "Could
not connect to the database: ", DBI->errstr, "\n";

I am BTW using Perl 5.005_03 built for i686-linux but this solution has
also worked fine with Active States Perl on Windows98.

/joakim sundén



Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Wed, 14 Jun 2000 15:52:45 GMT
From: usenet-9947@marc-haber.de (Marc Haber)
Subject: Re: Need SMTP-Sender for pre-formatted messages
Message-Id: <3947aa4b@news.ivm.net>

"Timothy H. Schilbach" <tschilbach@aodinc.com> wrote:
>Have you taken a look at Barr Graham's Mail-Tools module? I use this to
>forward the mail to a remote network and it acts as an SMTP. It can be found
>at CPAN:
>
>http://www.cpan.org/modules/by-authors/Graham_Barr/

Even this is a too high level interface for my needs. However, I
overlooked Net::SMTP which does exactly what I intend to do. A pity
that CPAN search doesn't return hits from the standard distribution as
well, I totally missed this.

Greetings
Marc

-- 
-------------------------------------- !! No courtesy copies, please !! -----
Marc Haber          |   " Questions are the         | Mailadresse im Header
Karlsruhe, Germany  |     Beginning of Wisdom "     | Fon: *49 721 966 32 15
Nordisch by Nature  | Lt. Worf, TNG "Rightful Heir" | Fax: *49 721 966 31 29


------------------------------

Date: Wed, 14 Jun 2000 16:20:00 -0500
From: "Timothy H. Schilbach" <tschilbach@aodinc.com>
Subject: NET::SMTP
Message-Id: <8i8su3$pc6$1@news.chatlink.com>

Ok here is a simple question and some background.  I have a script that
automatically activates user accounts when they signup for our services.
This works great except for the NET::SMTP section that is supposed to email
the client and then the administrator when the account is activated. I keep
getting this:

Can't call method "mail" on an undefined value at
I:\aodinc.com\cgi-bin\signup.pl line 298.

Below I have imput the lines of code as well. For some reason its not
recognizing the "mail" command. Without this varable, the message would not
be sent to the user. Any suggestions on how to overcome this? I have
commented the troubled line.

Code:
sub sendmailtouser {

if ($FORM{'email'} =~ /\@/) {

  use NET::SMTP;

  $smtp = Net::SMTP->new($server);
  $smtp->mail($ENV{USER});              # This is the line it says it cannot
recognize

  $smtp->to("$FORM{'email'}\n");

  $SMTP->data();
  $SMTP->datasend("From: Automated Server\n");
  $SMTP->datasend("To: $FORM{'first_name'}\n");
  $SMTP->datasend("Subject: Internet Service Order Completed.\n");
  $SMTP->datasend("\n");

  $SMTP->datasend("Below is your account information\n");
  $SMTP->datasend("please print this out for your reference:\n\n");
  $SMTP->datasend("Dial-Up Username: ${dialuser}\n");
  $SMTP->datasend("Dial-Up Password: $FORM{'password'}\n");
  $SMTP->datasend("Access Numbers: $location\n\n");

  $SMTP->datasend("Newsgroup Username: newservice\n");
  $SMTP->datasend("Newsgroup Password: begin\n");
  $SMTP->datasend("Newsgroup Server:   ${news}\n\n");

  if ($e =~ /1|3/) {
    $SMTP->datasend("Email Username: $FORM{'username'}\n");
    $SMTP->datasend("Email Password: $FORM{'password'}\n");
  }

  $SMTP->datasend("Incoming Mail Server: ${pop}\n");
  $SMTP->datasend("Outgoing Mail Server: ${smtp}\n\n");

  if ($e =~ /2|3/) {
    $SMTP->datasend("FTP Username: $FORM{'username'}\n");
    $SMTP->datasend("FTP Password: $FORM{'password'}\n");
    $SMTP->datasend("FTP Server: ${ftp}\n");
    $SMTP->datasend("Web Address:
http://members.${domain}/$FORM{'username'}/\n");
  }

  $SMTP->datasend("If you have any problems, please call $phone\n");
  $SMTP->datasend();

  $SMTP->quit;

} }

--
Timothy H. Schilbach
Alpha Omega Design Inc.
tschilbach@aodinc.com
1-877-263-7094
Visit our website at www.aodinc.com




------------------------------

Date: Wed, 14 Jun 2000 21:44:50 GMT
From: Dan Sugalski <dan@tuatha.sidhe.org>
Subject: Re: NET::SMTP
Message-Id: <m1T15.747$Zg4.4110@news1.rdc1.ct.home.com>

Timothy H. Schilbach <tschilbach@aodinc.com> wrote:
> This works great except for the NET::SMTP section

Are you sure you have the NET::SMTP module and not the Net::SMTP module?
Perl is, after all, case-sensitive...

					Dan


------------------------------

Date: Wed, 14 Jun 2000 15:17:34 GMT
From: nospam.newton@gmx.li (Philip 'Yes, that's my address' Newton)
Subject: Re: never mind !!
Message-Id: <39475dd4.187552753@news.nikoma.de>

On Wed, 14 Jun 2000 09:13:35 GMT, "Daniel van den Oord"
<danielxx@bart.nl> wrote:

> never mind had to use no strict "vars";

That's not considered the best way to get around use strict complaining.
See my other post.
-- 
Philip Newton <nospam.newton@gmx.li>
If you're not part of the solution, you're part of the precipitate.


------------------------------

Date: Wed, 14 Jun 2000 10:31:56 -0400
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: never mind !!
Message-Id: <slrn8kf5qs.48e.tadmc@magna.metronet.com>

On Wed, 14 Jun 2000 09:13:35 GMT, Daniel van den Oord <danielxx@bart.nl> wrote:

>never mind had to use no strict "vars";


You are being bad.

You may have to pay for that some day.

Much safer to do it without symbolic refs, which is
easily possible in your situation.


If you use symbolic references, you deserve to have bad
stuff happen to you.


-- 
    Tad McClellan                          SGML Consulting
    tadmc@metronet.com                     Perl programming
    Fort Worth, Texas


------------------------------

Date: 14 Jun 2000 16:10:06 GMT
From: bmetcalf@baynetworks.com (Brandon Metcalf)
Subject: Re: Non echo password
Message-Id: <8i8aou$ahg$1@spinner.corpeast.baynetworks.com>

rpearson@quebectel.com writes:

 > Is there a way to be able to get password from STDIN without echoing it ?

use Term::ReadKey;
ReadMode 'noecho';
chomp($password = ReadLine 0);

or you could simply use stty to turn echo off

system("stty", "-echo");
chomp($password = <STDIN>);

Brandon


------------------------------

Date: Wed, 14 Jun 2000 13:17:03 -0400
From: "Russel Pearson" <rpearson@quebectel.com>
Subject: Re: Non echo password
Message-Id: <k6P15.20402$NS6.278645@news.globetrotter.net>

Is it the same technique in NT environnement ?




------------------------------

Date: Wed, 14 Jun 2000 17:18:52 GMT
From: Ilja Tabachnik <billy@arnis-bsl.com>
Subject: Re: Non echo password
Message-Id: <8i8epa$5rh$1@nnrp1.deja.com>

In article <KZM15.20399$NS6.278284@news.globetrotter.net>,
  "Russel Pearson" <rpearson@quebectel.com> wrote:
> Is there a way to be able to get password from STDIN without echoing
it ?

Looks like a FAQ.

Search your local perldoc perlfaq8 or
http://www.cpan.org/doc/manual/html/pod/perlfaq8.html
for "How do I ask the user for a password?".

Good luck.
Ilja.


Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Wed, 14 Jun 2000 15:10:40 -0500
From: Dale Bohl <dbohl@sgi.com>
Subject: Re: Non echo password
Message-Id: <3947E6C0.36DA5FDE@sgi.com>

Russel Pearson wrote:
> 
> Is there a way to be able to get password from STDIN without echoing it ?
> 
> Thanks in advance


Check this out...Unix only

#!/usr/bin/perl -w
#
# This script verifies a user's password.

$pwd = (getpwuid($<))[1];
$salt = substr($pwd, 0, 2);
system "/usr/bin/stty", "-echo";             # turn off echoing

print "Enter Your Password: ";
chop($word = <STDIN>);
print "\n";
system "/usr/bin/stty", "echo";              # turn on echoing

if (crypt($word, $salt) ne $pwd) {
   die "Sorry...That is NOT your Password\n";
} else {
   print "That IS your correct Password.\n";
}

-- 

Thanks,
Dale

Dale Bohl
SGI Information Services
dbohl@sgi.com
(715)-726-8406
http://wwwcf.americas.sgi.com/~dbohl/


------------------------------

Date: Wed, 14 Jun 2000 11:22:07 -0500
From: Bob Martin <bob@inu.net>
Subject: ODBC, MSSQL and Unix
Message-Id: <3947B12F.4D1396D6@inu.net>

Need to use perl/DBI to talk to a MSSQL server on NT. Anyone know where
I can get a good (free is _very_ good) driver? Any other suggestions?

Thanks
Bob Martin


------------------------------

Date: Wed, 14 Jun 2000 17:28:48 GMT
From: Dan Wilga <dwilgaREMOVE@mtholyoke.edu>
Subject: Re: ODBC, MSSQL and Unix
Message-Id: <dwilgaREMOVE-6FD47A.13285214062000@news.mtholyoke.edu>

In article <3947B12F.4D1396D6@inu.net>, Bob Martin <bob@inu.net> wrote:

> Need to use perl/DBI to talk to a MSSQL server on NT. Anyone know where
> I can get a good (free is _very_ good) driver? Any other suggestions?

That depends somewhat on what the client OS is. One source is OpenLink 
(www.openlinksw.com).

Dan Wilga          dwilgaREMOVE@mtholyoke.edu
** Remove the REMOVE in my address address to reply reply  **


------------------------------

Date: Wed, 14 Jun 2000 21:01:38 GMT
From: rrubin@rotor.net
Subject: OLE and CGI ?? Not working !
Message-Id: <8i8rr5$gjv$1@nnrp1.deja.com>

Hello,

I am trying to run a CGi script that performs a certain function
using OLE. The script runs great from the command line but once I
embed the CGI calls into the script it doesn't work.

The following code is just an example. This is true to any OLE or
COM object I use.  I am currently running this on WIndows NT and
Personal Web Server.

Working command line version:

=============

use OLE;

$ie = CreateObject OLE "InternetExplorer.Application.1" ||
  die "CreateObject: $!";
$ie->{Visible} = 1;
$ie->Navigate("http://www.cnn.com");

==============

Not working CGI version

===============

use OLE;
use CGI;
$co=new CGI;



print $co->header();

print $co->start_html;

$ie = CreateObject OLE "InternetExplorer.Application.1" ||
  die "CreateObject: $!";
$ie->{Visible} = 1;
$ie->Navigate("http://www.cnn.com");

print $co->end_html;


Any help is appreciated.

RR

rrubin@rotor.net


Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: 16 Sep 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 16 Sep 99)
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.  

| NOTE: The mail to news gateway, and thus the ability to submit articles
| through this service to the newsgroup, has been removed. I do not have
| time to individually vet each article to make sure that someone isn't
| abusing the service, and I no longer have any desire to waste my time
| dealing with the campus admins when some fool complains to them about an
| article that has come through the gateway instead of complaining
| to the source.

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 V9 Issue 3359
**************************************


home help back first fref pref prev next nref lref last post