Could we also agree a suitable acronym for all Perl Questions and replies.
I suggest [BPQ] for Beginners Perl Question.
That way people can set-up an email folder and move them using a rule.
This would go at the start of the subject line.
John Preece
Technical Consultant
Tel : 0121 585 255
> I hope this helps, and don't forget to read:
>
> perldoc perlmod
> perldoc perlmodlib
> perldoc constant
> perldoc Exporter
Ooo, a bibliography at the end of the specific advice -- that's a *great*
idea for a beginners list. We should make that a convention :)
> Hi guys and girls , does any one have a web link to perl specifications,
> (For example, are the specifications for a variable name) ??
> Thx
On Mon, Apr 23, 2001 at 06:20:16AM -0700, Zysman, Roiy wrote:
>
> > Hi guys and girls , does any one have a web link to perl specifications,
> > (For example, are the specifications for a variable name) ??
> > Thx
If you're talking about style, try
perldoc perlstyle
--
Paul Johnson - [EMA
Take a look at the Perl Style Guide...
http://www.perl.com/CPAN-local/doc/manual/html/pod/perlstyle.html
Brent
"Zysman, Roiy" <[EMAIL PROTECTE
[Copying the list on a reply to a private email, with permission]
A placeholder consists of a single question mark ("?") in your query
statement. It replaces a single value in your SQL statement. For example:
Without placeholders:
INSERT INTO MYTABLE VALUES ('Mark', 'Nutter', 'foo', 'bar', '
Is there a better way of doing this?
Thanks!
Dave
if ($in{'price'} eq "") {print '• Missing '; }
elsif (&checkPrice($in{'price'})) {
print '• Wrong Format';
}
sub checkPrice{
if ($_[0] =~ /\$?(\d*)(\.\d{0,2})?/) {
return 1;
} else {
return 0;
}
}
Allowable input:
On Sun, Apr 22, 2001 at 11:28:08PM -0700, Helio S. Junior wrote:
:
: I would like to know if i could develop Palm OS
: applications using Perl.
: Is there any package out there to do that?
: Thanks for your attention.
Perl has not been ported to the Palm OS yet, unfortunatley.
--
Casey West
On Mon, Apr 23, 2001 at 11:38:42AM -0400, David Gilden wrote:
> Is there a better way of doing this?
Hmmm. Where to start? :-)
> Thanks!
> Dave
>
>
>
> if ($in{'price'} eq "") {print '• Missing '; }
> elsif (&checkPrice($in{'price'})) {
> print '• Wrong Format';
> }
>
>
>
>
Hello,
Sorry to ask this, as I am quite new at this.
And the online class that I am just now finishing has
lots of bad code for examples!
>From this list:
print "'$file' => '$newfile'\n";
^
What does this line mean, this a renaming convention?
Thanks
Dave
-
At 02:28 AM 4/23/2001, you wrote:
>Hello !
>
>
>I would like to know if i could develop Palm OS
>applications using Perl.
>Is there any package out there to do that?
>Thanks for your attention.
>
>
>H3li0
The short answer is no.
The slightly longer answer is that so far no one has made perl run
On Mon, Apr 23, 2001 at 12:33:00PM -0400, David Gilden wrote:
> Hello,
> Sorry to ask this, as I am quite new at this.
> And the online class that I am just now finishing has
> lots of bad code for examples!
>
> >From this list:
>
> print "'$file' => '$newfile'\n";
> ^
>
On Mon, Apr 23, 2001 at 11:38:42AM -0400, David Gilden wrote:
: Is there a better way of doing this?
Dave, here is my take on it, hopefully commented well:
#!/usr/local/bin/perl -w
use strict;
$|++;
while ( ) {
chomp;
print( &validate( $_ ) ? 'valid entry' : 'try again punk' );
print "\
At 06:23 PM 4/19/2001, you wrote:
>I have a question about the Perl documentation I find on the web that
>explains the usage of Perl modules. I come across this situation somewhat
>frequently where I need to do something, find a module that can do it, but
>just can't figure out from the basic info
At 07:33 PM 4/22/2001, you wrote:
>Sean O'Leary -- Damn that was a good explaination! I
>felt like I understood $_ very well before, but I
>understand it even better now. A very perlish post
>indeed. Larry the linguist would be proud!
>
>Matt
Thanks. : ) I'm glad I could help out.
There are lo
- Original Message -
From: David Gilden <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, April 23, 2001 6:33 PM
Subject: print with => ??
> Hello,
> Sorry to ask this, as I am quite new at this.
> And the online class that I am just now finishing has
> lots of bad code for exam
when i try to run perldoc, i get the following error. do i need to
alter perldoc itself? i can run all sorts of other perl programs
with modules just fine.
> [boex@rootabega boex]$ perldoc
> Can't locate warnings.pm in @INC (@INC contains:
> /usr/lib/perl5/5.00503/i386-linux /u
Could you repost the answer? I just joined this group and would love to
read the great answer referenced in the post.
Thanks,
Mike
-Original Message-
From: Sean O'Leary [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 23, 2001 12:30
To: [EMAIL PROTECTED]
Subject: Re: help me understand $
On Mon, Apr 23, 2001 at 01:08:36PM -0500, Hanby, Mike wrote:
: Could you repost the answer? I just joined this group and would love to
: read the great answer referenced in the post.
Don't forget about the archives at:
http://archive.develooper.com/beginners%40perl.org/
--
Casey West
Please, do not repost. Mike, please check the archive at
http://archive.develooper.com/beginners%40perl.org/
If we have people reposting (and reposting and reposting) this list will
become quite cluttered.
Thanks,
Dan
"Hanby, Mike" wrote:
>
> Could you repost the answer? I just join
On Mon, Apr 23, 2001 at 01:06:06PM -0500, Boex,Matthew W. wrote:
:
: when i try to run perldoc, i get the following error. do i need to
: alter perldoc itself? i can run all sorts of other perl programs
: with modules just fine.
>From below, it seems that you have a perldoc built f
Perl guru's,
Looking for any examples of using the "stty -echo" command with the the
expect perl module. I'm trying to spawn an ssh session and use an encrypted
password from a flat file. The only problem is hiding the output from the
expect session. Is it possible to make the password hidden
Would it be possible to add a Reply-To header to all the messages
originating from this list. That way we would point back to the list for
regular replies, and we could still get the original poster's info from the
From header.
I think this would be a good idea, and pretty convenient. It s
On Mon, Apr 23, 2001 at 01:15:13PM -0400, David Gilden wrote:
[ brought back to the list with permission ]
> my camel learning perl book has hashs with the key in quotes,
> whats going on with this?
In the early days this was necessary, otherwise the key would be
interpreted as a function and i
The Term::ReadLine package is one option.. You might also try the native
perl function getc.
Bruce W. Lowther
[EMAIL PROTECTED]
Micron Technology, Inc.
Boise, Idaho
-Original Message-
From: Goodman Kristi - kgoodm [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 23, 2001 1:05 PM
To: '[EMAI
Speaking of aging camels, is the Camel book still the best reference to
have? I am new to Perl and have the Llama book. It's been a good starting
place but one day I see myself moving past it. I would like something that
covers the language in more detail and deals with Data Munging, XML, CGI,
Dear Casey and the list,
Thanks for your all of your valuable help,
What is $|++ for?
#!/usr/local/bin/perl -w
use strict;
$|++;
while ( ) {
chomp;
print( &validate( $_ ) ? 'valid entry' : 'try again punk' );
print "\n";
}
sub validate {
my $currency = shift;
# return false if we
On Mon, Apr 23, 2001 at 07:32:32PM -, Stout, Joel R wrote:
> Speaking of aging camels, is the Camel book still the best reference to
> have? I am new to Perl and have the Llama book. It's been a good starting
> place but one day I see myself moving past it. I would like something that
> co
- Original Message -
From: David Gilden <[EMAIL PROTECTED]>
To: Casey West <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Monday, April 23, 2001 9:23 PM
Subject: quick PERL question
> Dear Casey and the list,
> Thanks for your all of your valuable help,
>
> What is $|++ for?
>
> #!/u
On Mon, Apr 23, 2001 at 03:23:06PM -0400, David Gilden wrote:
> What is $|++ for?
perldoc perlvar
It sets the output to be unbuffered. Personally I'd use $| = 1 just to
be explicit, and in case some joker had previously set it to -1 :-)
> I could not seem to include the sub chekPrice in my if
- Original Message -
From: Paul Johnson <[EMAIL PROTECTED]>
To: David Gilden <[EMAIL PROTECTED]>
Cc: Casey West <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Monday, April 23, 2001 10:30 PM
Subject: Re: quick PERL question
> >
> > $x = &checkPrice($in{'price'});
> > if ( ($in{'name'} e
Hi all.
I'm trying to do what I think is a very simple thing. I want to read
keyboard input char by char and time the difference between each keystroke.
I've tried using
while (sysread STDIN, $key, 1) {
dostuff
};
but that seems to be doing some kind of buffering so that the body of th
At 05:25 PM 4/23/2001, Janet Lee wrote:
>Hi all.
>
>I'm trying to do what I think is a very simple thing. I want to read
>keyboard input char by char and time the difference between each keystroke.
>I've tried using
>
>while (sysread STDIN, $key, 1) {
> dostuff
>};
>
>but that seems to be
Hello everyone,
I'm new to PERL ...
and have a question about a style/format I've observed
where 'my' is placed in front of arrays, hashes - you name it ...
At first I interpreted this as a Nemonic name but several
functions might have this in the same code .. what g
I can't see those acronyms working because a beginner is just going to ask
the question - and at best they're going to try and guess what acronym to
use with their limited knowledge of Perl and limited perspective with which
to make a worthwhile guess
and if you continue to do what you're doing -
from my experience in c.l.p.misc some people take those bibliographies as a
disguised RTFMs .. I'd love to see it for all posts - but am afraid at how
some beginners might interpret it
--
jason king
No children may attend school with their breath smelling of "wild
onions" in West Virginia
Roiy Zysman writes ..
> Hi guys and girls , does any one have a web link to perl specifications,
> (For example, are the specifications for a variable name) ??
while others have pointed you to perlstyle - to me your question reads more
that you're after the technical specifications of what can a
Sean O'Leary writes ..
>Would it be possible to add a Reply-To header to all the messages
>originating from this list. That way we would point back to the list
>for regular replies, and we could still get the original poster's info
>from the From header.
excellent idea
>I would also like to sec
On Mon, 23 Apr 2001, SunDog wrote:
> where 'my' is placed in front of arrays, hashes - you name it ...
The "my" keyword makes a variable local. It's a scoping mechanism, and is
primarily used inside function definitions to keep the namespace
uncluttered.
--
Todd A. Jacobs
CodeGnome Consult
The perl documentation (perldoc -f my) has this to say about the perl
builtin "my":
A my declares the listed variables to be local (lexically) to the
enclosing block, file, or eval. If more than one value is listed, the
list must be placed in parentheses. See Private Variables via my()
Matt Blatchley writes ..
>Looking for any examples of using the "stty -echo" command with the
>the expect perl module. I'm trying to spawn an ssh session and use an
>encrypted password from a flat file. The only problem is hiding the
>output from the expect session. Is it possible to make the pas
On Tue, Apr 24, 2001 at 09:59:46AM +1000, King, Jason wrote:
: from my experience in c.l.p.misc some people take those bibliographies as a
: disguised RTFMs .. I'd love to see it for all posts - but am afraid at how
: some beginners might interpret it
It is extremely welcome provided there is a n
David Gilden writes ..
>Sorry to ask this, as I am quite new at this.
>And the online class that I am just now finishing has
>lots of bad code for examples!
>
>>From this list:
>
> print "'$file' => '$newfile'\n";
> ^
>
>What does this line mean, this a renaming convention?
M.W. Koskamp writes ..
>The special variable $| sets the autoflush. See PERLVAR documentation.
>Whats this person does is a dirty way of setting $| to a true
>value (not 0 or undef).
>Default = 0.
why do you say 'dirty' ? .. do you just mean 'less readable' ? .. or are you
implying some other
Why bother with acronyms that many won't use when in most email programs
it is trivial to write an email filter that examines whether "To: or
CC:" contains "[EMAIL PROTECTED]" and send it to a particular folder?
(or write two filters, one for "To:" and one for "CC:", both sending to
the same folde
Original from the class:
print "\n";
Is this bad style?
print '',"\n";
better?
print ''. "\n";
I do believe that these 3 statements are all equivalent.
Thanks
Dave
David Gilden writes ..
>Original from the class:
>
>print "\n";
>
>
>Is this bad style?
yep .. avoid backwhacks at all costs - that's my opinion
>print '',"\n";
>
>better?
yep .. much better
>print ''. "\n";
also good - but generally accepted as inferior to the second snippet
>I do believe
Hi
Kindly advice me how to install Perl Software in the below Operating
Systems:
1. Linux
2. Windows 98
Thanks,
SV
Thank you for the information.
;-)
H3li0
--- Sean O'Leary <[EMAIL PROTECTED]> wrote:
> At 02:28 AM 4/23/2001, you wrote:
> >Hello !
> >
> >
> >I would like to know if i could develop Palm OS
> >applications using Perl.
> >Is there any package out there to do that?
> >Thanks for your attention.
How do I get help on some modules like what are services available in
particular module say NET::FTP etc etc
Thanks
Amar
Amarnath Honnavalli Anantharamaiah asks ..
>How do I get help on some modules like what are services available in
>particular module say NET::FTP etc etc
all command-line distributions of Perl ship with a utility called perldoc ..
for modules like Net::FTP you should be able to type the foll
Amarnath Honnavalli Anantharamaiah asks ..
>How do I get help on some modules like what are services available in
>particular module say NET::FTP etc etc
all command-line distributions of Perl ship with a utility called perldoc ..
for modules like Net::FTP you should be able to type the foll
What I have to do if I get the following message
$ perldoc NET::FTP
No documentation found for "NET::FTP".
Does this mean that there is no NET::FTP module on my box or there is no
documentation available for this or the path is not set for getting the
documentation. How do I do that.
How can I k
I have this line of code in my program:
print "Did everything look ok? (Y/N)";
chomp ($check = );
$check = "\U$check";
if ("\U$check" ne "Y") {die "Well. . . go back and try again until you get
it right!!!\n"};
How would I fix it where the user did not have to ENTER after they typed a Y
or N.
54 matches
Mail list logo