Hi everyone, thanks for the help last time!
if I have two strings
$word="cows";
and another given string:
$givenword="XXX-"; #with the same length as $word !!!
what I want to do is transform "XXX_" --> "cow-"
I have tried but cant figure out going characterwise, all I get in the
end is like t
perldoc -q PACKAGE
José.
> -Original Message-
> From: Trond Hagen [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 11, 2002 7:09 AM
> To: [EMAIL PROTECTED]
> Subject: Which package am I in ?
>
>
> Hi!
>
> I want to know which package I'm in?
> Any help?
>
> package go
>
> prin
Hi everyone, thanks for the help last time!
if I have the string
$word="cows";
and another given string:
$givenword="XXX-"; #with the same length as $word !!!
what I want to do is transform "XXX-" --> "cow-"
I have tried but cant figure out going characterwise, all I get in the
end is like th
Hello Erik
It's not clear exactly what you want, but something like this should do the
job:
for (my $i = 0; $i < length $word; ++$i)
{
substr ($word, $i, 1) = '-' unless substr ($givenword, $i, 1) eq
'X';
}
HTH,
Rob
- Original Message -
From: "Erik Browaldh" <[EMA
On Tue, 10 Dec 2002 18:37:50 -0500, [EMAIL PROTECTED] (Chad
Kellerman) wrote:
>Mark,
>This is a pain to install. I would do it thru CPAN.
>perl -MCPAN -e shell
>cpan>install Net::SSH::Perl
> I fyou don't have root access to install perl modules, try to use
>Net::SSH.
>
>use strict;
>use warni
Hi all.
I need to "cast" a scalar reference (SCALAR0x) into a reference to
an object that I can use. (in other words, bless it).
How can I do it?
thanks,
ruthie
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
I am declaring my constants like this.
use constant SOURCE => "/path/folder/"
Now how would I use this constant is a print statement or any statement
for that matter.
print "$SOURCE" does not work and of course print "source" will not
work.
I understand that this works but I do not understand wha
print SOURCE;
> -Original Message-
> From: Paul Kraus [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 11, 2002 9:17 AM
> To: Perl
> Subject: Constants and Hash Question
>
>
> I am declaring my constants like this.
> use constant SOURCE => "/path/folder/"
> Now how would I use this
ok but lets say I am doing this
$copydir = `cp --preserve --recursive --update
SOURCE/$ini{$section}{path} DEST/$ini{$section}{machine}`;
> -Original Message-
> From: Kipp, James [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 11, 2002 9:29 AM
> To: 'Paul Kraus'; Perl
> Subjec
- Original Message -
From: "Paul Kraus" <[EMAIL PROTECTED]>
To: "Perl" <[EMAIL PROTECTED]>
Sent: Wednesday, December 11, 2002 2:16 PM
Subject: Constants and Hash Question
> I am declaring my constants like this.
> use constant SOURCE => "/path/folder/"
> Now how would I use this constant
$command="cp --preserve --recursive --update ". SOURCE
."/$ini{$section}{path}"..
$copydir = `$command`;
-Original Message-
From: Paul Kraus [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 11, 2002 2:38 PM
To: 'Kipp, James'; 'Perl'
Subject: RE: Constants and Hash Question
ok b
>
> ok but lets say I am doing this
>
> $copydir = `cp --preserve --recursive --update
> SOURCE/$ini{$section}{path} DEST/$ini{$section}{machine}`;
>
could use concatenation.
$copydir = `"cp --preserve --recursive --update" .
SOURCE . "/$ini{$section}{path} DEST/$ini{$section}{machine}"`
Paul
You can use SOURCE etc. roughly anywhere you could use the corresponding
quoted string.
$source = SOURCE."/$ini{$section}{path}";
$dest = DEST."/$ini{$section}{machine}";
$copydir = `cp --preserve --recursive --update $source $dest';
Cheers,
Rob
- Original Message -
Fr
On Wed, 2002-12-11 at 13:55, Ruth Albocher wrote:
> I need to "cast" a scalar reference (SCALAR0x) into a reference to
> an object that I can use. (in other words, bless it).
> How can I do it?
my $object = bless $scalar_reference, 'Your::Class';
--
Nigel Wetters, Senior Programmer, Develop
Hello all,
I'm obviously making a silly mistake here and would appreciate it if
someone can point out my error. I am trying to populate a hash of a
hash in a while() loop. Here is what I have:
my $i = 0;
my %hash = ();
while () {
$hash{SOMETHING}{$i} = $something;
$hash{SOMETH
>
> Hello all,
>
> I'm obviously making a silly mistake here and would appreciate it if
> someone can point out my error. I am trying to populate a hash of a
> hash in a while() loop. Here is what I have:
>
> my $i = 0;
>
> my %hash = ();
>
> while () {
> $hash{SOMETHING}{$i} = $so
I am not populating from a file, actually. I'm populating from the
output of $sth->fetch from DBI. The $something and $something_else
variables in this case are numbers which have been defined by the output
of that method.
If I do $hash{SOMETHING}{0} = $something;
Then my hash is populated
Hi!
I am trying to get the current file time by the following:
$file_datetime = ctime( stat( "$file_name" )->mtime );
All I get is the time that the file was created. What am I doing wrong?
Thanks,
Jerry
>
> If I do $hash{SOMETHING}{0} = $something;
>
> Then my hash is populated correctly. I am only not getting
> results if I
> do $hash{SOMETHING}{$i} = $something. The key here is how I am using
> the variable $i in my hash.
>
>
I tried this on my machine and it worked fine:
my $i;
for ( 1
@stat = stat $file;
$time = @stat[10];
print $time;
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Jerry Preston" <[EMAIL PROTECTED]>
Reply-To: <[EMAIL PROTECTED]>
To: "Beginners Perl" <[EMAIL PROTECTED]>
Subject: file time
Date: We
Hi!
no, its still not changing the letters (but thanks Rob)..
I have a string:
$givenword="YY-"
and another string (the original)
$word="not"
now I want $givenword to look like this:
$givenword="no-"
?
thanks in advanced!
Erik
Rob Dixon wrote:
Hello Erik
It's not clear exactly what you
Use eval and check $@ for error checking.
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Paul Kraus" <[EMAIL PROTECTED]>
To: "'Perl'" <[EMAIL PROTECTED]>
Subject: Return Status
Date: Tue, 10 Dec 2002 17:27:36 -0500
instead of setti
Quite. What you've written looks fine Ian. But you've probably shown us what
you /meant/ rather than what you've actually coded :-}
Cheers,
Rob
- Original Message -
From: "Kipp, James" <[EMAIL PROTECTED]>
To: "'Ian Zapczynski'" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, D
Yes, Rob, you are absolutely correct. Unfortunately, I still lack
confidence in my coding abilities, so when something doesn't work, I
seem to assume I just don't know how to do it properly. In reality, I
just made a dumb mistake, which is partially where this lack of
confidence comes from. :
Hi everybody !!
Thanks a lot for the references about e-mail manipulation script at
perlmonks , ...It works great ... but I have another problem ... look
the thing is that I need to run the script over every mail in the queue,
I'm using sendmail but it generates a flat text file under
/var/spo
Hi Erik
You might like this!
$givenword =~ s/[a-z]/substr $word, pos $givenword, 1/egi;
Cheers,
R
- Original Message -
From: "Erik Browaldh" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, December 11, 2002 4:01 PM
Subject: Re: help with substitution
> Hi!
>
> no,
When I run my program I get this error at this line.
[root@fileserver pdkbackup]# ./backup
exists argument is not a HASH or ARRAY element at ./backup line 29.
if (exists %{$ini{$section}}, email){
print "$ini{$section}{email}\n\n";
}
This statement is taken verbatim from the perldoc Conf
You use "exists" on a hash key, not an entire hash...
if (exists $ini{$section}{email}){
...
}
Rob
-Original Message-
From: Paul Kraus [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 11, 2002 11:51 AM
To: Perl
Subject: Config::Ini
When I run my program I get this error at this l
stat array
--
1. dev
2. ino
3. mode
4. nlink
5. uid
6. gid
7. rdev
8. size
9. atime
10.mtime
11.ctime
12.blksize
13.blocks
@array = stat(filename);
print "$arary[10]"; #prints mtime.
Buy learning perl and programming perl. Worth every single penny.
> -Original Message-
> From: J
Greetings!
Is there a searchable archive of this list? I'd like to be able to see
if my questions have been answered before I ask them, as I'm sure most
of them have been, including this one.
Thanks!
Rob
__
Do you Yahoo!?
Yahoo! Mail Plus - Pow
> -Original Message-
> From: Robbie Staufer [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 12:22 PM
> To: [EMAIL PROTECTED]
> Subject: first row of database
>
>
> Hi,
>
> Is there a way to refer to the first row of a database (row 0?) ?
>
> For example, the first row of m
Try this:
http://groups.google.com/advanced_group_search?group=perl.beginners
José.
> -Original Message-
> From: Rob Richardson [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 11, 2002 6:02 PM
> To: [EMAIL PROTECTED]
> Subject: Searchable archive?
>
>
> Greetings!
>
> Is there
You just need to index the hash element:
if ( exists $ini{$section} ) { .. }
Not sure about that " , email " though!
Rob
- Original Message -
From: "Paul Kraus" <[EMAIL PROTECTED]>
To: "Perl" <[EMAIL PROTECTED]>
Sent: Wednesday, December 11, 2002 4:51 PM
Subject: Config::Ini
> Whe
An other option is to check first the FAQ:
1) FAQ from this list
http://learn.perl.org/beginners-faq
2) FAQ from perldoc
perldoc -q
Type
perldoc perldoc
For more info.
HTH,
José.
> -Original Message-
> From: Rob Richardson [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 11, 20
Hello all,
I am a complete newbie and am trying to do a couple of things but was
not able to. Any assitance is welcome.
If I have a dir structure G:\abc\efg\qrs.txt:
1) How can I list the entire structure under G:\abc along with all the dirs. under G:\abc\ right upto the file qrs.txt ?
In th
Does Word2000 understand Unicode? Does it default to trying to read
Unicode, rather than ASCII or the like? I have used jEdit with success
to read/write Unicode files.
--Chris
On Monday, December 9, 2002, at 02:30 PM, Raghupathy, Ramesh . wrote:
Hi,
I am using perl 5.8.0 for windows to
Often, but not always, I see the last line in a perl module as
1;
Is this to force the module to exit 'true', forcing it to compile?
Thanks!
Jeff
_
Tired of spam? Get advanced junk mail protection with MSN 8.
http://join
John,
You went way out of your way in helping me here. I
really appreciate it.
I will try to remember these rules. The checking is a
great idea. I also tend to over complicate things, I
have to remember that.
Thanks again,
Al Moote
--- "John W. Krahn" <[EMAIL PROTECTED]> wrote: > Alan
moote
I have recently discovered qr// and it seems to be the only way to cut and
paste a functioning regex literal into a variable assignment. Notice below I
had to do little more than cut and paste the regex literal from Method 3
into the qr expression in Method 1. Nifty. That is PRECISELY what I want
When I read an Excel file in, ParseExcel reformates the year to
dd-mm-*yy* (for example 10 dec 2002 is 10-12-*02*).
I don't want this to happen, the format should stay the way it was
dd-mm-** (10-12-*2002*).
Here is the code:
use Spreadsheet::ParseExcel;
Hi,
can anyone help me, i want to include the ouput of a perl file within an html file,
without using a seperate frame. I am familiar with php, is there a way to include like
there is in php? Or do i have to output the HTML from the perl script?
Any help very much appreciated... i left my book
Hi,
can anyone help me, i want to include the ouput of a perl file within an
html file, without using a seperate frame. I am familiar with php, is there
a way to include like there is in php? Or do i have to output the HTML from
the perl script?
Any help very much appreciated... i left my books a
See this archive :
http://archive.develooper.com/beginners%40perl.org/msg38109.html
José.
> -Original Message-
> From: popeye _ [mailto:[EMAIL PROTECTED]]
> Sent: Monday, December 09, 2002 11:47 PM
> To: [EMAIL PROTECTED]
> Subject: Last Line in Packages
>
>
> Often, but not always, I
Hi i want to execute an linux command as atotally separeted from the =
father process
Is this going to work?
Is it wrong?
my script.
fork ("perl anotherscript.pl");
.
my script go on...
Thanks
What/when/where/how might one come across the ?character? '\000' -> that's
backslash followed by three zero's.
I ask because i've just come acress a regex for parsing valid directories and
it has that as an m/...[^\000].../ (as in, we don't want to find this...)
Thanks
-
Trond Hagen wrote:
> Hi!
>
> I want to know which package I'm in?
> Any help?
>
> package go
>
> print "Now I'm here: ??PACKAGE??\n" # <- ??PACKAGE?? can be replaced by?
>
>
> Thanks! :-)
>
> trond
try:
#!/usr/bin/perl -w
use strict;
print "I am in ",__PACKAGE__,"\n";
package Paris;
pri
> -Original Message-
> From: NYIMI Jose (BMB) [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, December 11, 2002 1:00 PM
> To: popeye _; [EMAIL PROTECTED]
> Subject: RE: Last Line in Packages
>
>
> See this archive :
>
> http://archive.develooper.com/beginners%40perl.org/msg38109.html
>
>
> -Original Message-
> From: Andre [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 10, 2002 9:55 PM
> To: [EMAIL PROTECTED]
> Subject: FORK USE ?
>
>
> Hi i want to execute an linux command as atotally separeted
> from the =
> father process
> Is it wrong?
> my script.
> fork (
Cool... Thanks a bundle
-Chris
On Wednesday 11 December 2002 12:45 pm, Kevin Meltzer wrote:
> \000 is a null character.
>
> Cheers,
> Kevin
>
> On Wed, Dec 11, 2002 at 12:38:49PM -0600, Dr. Poo ([EMAIL PROTECTED])
said something similar to:
> > What/when/where/how might one come across t
From: "Dr. Poo" <[EMAIL PROTECTED]>
> What/when/where/how might one come across the ?character? '\000' ->
> that's backslash followed by three zero's.
>
It's an escape sequence for a character with code 0.
The escape seqences have on of these formats:
backslash plus one letter
ba
From: "Todd W" <[EMAIL PROTECTED]>
> Think about this:
>
> my($frank) = Person->new(); # class method -- $_[0] eq 'Person';
>
> my($jimmy) = Person::new(); # plain 'ol function call -- $_[0] eq '';
Well $_[0] does eq '', but so does $_[78548654].
In this case $_[0] is undef and scalar(@_) == 0.
Paul,
I am a Perl newbie, but I am employed as a Visual C++ and Visual Basic
programmer. I'm having trouble figuring out what your construct is
doing. For reference, here it is:
> @website[
> map $_->[0],
> sort { $b->[1] <=> $a->[1] }
> map [ $_, $array[$_
Paul,
I am a Perl newbie, but I am employed as a Visual C++ and Visual Basic
programmer. I'm having trouble figuring out what your construct is
doing. For reference, here it is:
> @website[
> map $_->[0],
> sort { $b->[1] <=> $a->[1] }
> map [ $_, $array[$_
This is my first real Perl program outside of the learning to Perl
exercises. Any thoughts, opinions, or suggestions are greatly
appreciated.
I used system copy rather file::copy for simplicity. It seems like doing
the same kind of recursive copy with file::copy would have made this a
very large p
I have a list of names, separated by the '/' character in a variable, $list,
and a name in the variable $name. If the name appears in the list, I want to
remove it and clean up $list. It takes me 4 calls to s///, and it looks
clunky. I have a feeling that someone out there on this list will k
How can I justify text. For example lets say I want a 50 character line
that contains "TITLE", and I want it centered.
Can this be done with printf?
Paul Kraus
Network Administrator
PEL Supply Company
216.267.5775 Voice
216-267-6176 Fax
www.pelsupply.com
--
To unsubscribe, e-mail: [EMAIL PROTEC
What about just
$list =~ s|/?$name/?||
But you should be careful about that in case $name appears in the middle of
a word
e.g., cat and catmandu
perhaps
$list =~ s|/?\b$name\b/?||;
Tanton
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, December 11,
.--[ [EMAIL PROTECTED] wrote (2002/12/11 at 14:49:15) ]--
|
| I have a list of names, separated by the '/' character in a variable,
| $list, and a name in the variable $name. If the name appears in the
| list, I want to remove it and clean up $list. It takes me 4 calls to
|
In a message dated 12/11/2002 11:54:48 AM Pacific Standard Time,
[EMAIL PROTECTED] writes:
> What about just
> $list =~ s|/?$name/?||
If $name appears in the middle of the list, this removes both '/' characters.
This was my first guess as well.
> But you should be careful about that in case
> In a message dated 12/11/2002 11:54:48 AM Pacific Standard Time,
> [EMAIL PROTECTED] writes:
>
>
> > What about just
> > $list =~ s|/?$name/?||
>
> If $name appears in the middle of the list, this removes both '/'
characters.
> This was my first guess as well.
Ah, didn't think about that one :)
Forget that...this works in all cases:
$list =~ s|((?!.)/)\b$name\b/?||;
- Original Message -
From: "Tanton Gibbs" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, December 11, 2002 3:06 PM
Subject: Re: Removing a name from a list - advanced regexp - TIMT
ARRR Typo
$list =~ s|((?!.)/)?\b$name\b/?||;
- Original Message -
From: "Tanton Gibbs" <[EMAIL PROTECTED]>
To: "Tanton Gibbs" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>
Sent: Wednesday, December 11, 2002 3:09 PM
Subject: Re: Removing a name from a list - advance
You might try Damian Conway's Text-Autoformat from CPAN:
Template::Plugin::Autoformat
Interface to Text::Autoformat module
Template-Toolkit-2.08 - 30 Jul 2002 - Andy Wardley
Text::Autoformat
Automatic and manual text wrapping and reformating formatting
Text-Autoformat-1.04 - 04 Dec 2
In a message dated 12/11/2002 12:00:43 PM Pacific Standard Time,
[EMAIL PROTECTED] writes:
> How about this:
>
> $list =~ s|/$name||;
> $list =~ s|^/||;
>
> If it's at the end, it will remove the last /.
> If it's in the middle it will fill in correctly.
> If it's
> If it's on the front, it won't remove it because it doesn't have a
preceeding
> / in that case.
I'm confused...according to your first post:
>$list =~ s|$name||; # remove $name from the list if it's in the list
>$list =~ s|//|/|; # if $name was in the middle of the list, it would have
>left beh
Regex?
$var =~ s/\b\**\**\b//; # deletes *
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: Max <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: Spreadsheet::ParseExcel date problem (year is being reformatted)
Date: Tue, 10 Dec 2002
How about using HTML?
$var
Put that in a var and print it out. Ofcourse, set content-type to text-html.
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Paul Kraus" <[EMAIL PROTECTED]>
To: "Perl" <[EMAIL PROTECTED]>
Subject: Center
Hmm. You could try to declare a variabele on STDOUT...
Any more, I dunno...
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "Adam Wilson" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Subject: include .pl in html
Date: Tue, 10 Dec 2002
You can do this? Perl will output the text to a file using html? Meaning
that just the text as it should be and not the tags will print? Cool :)
I did not know that. Where would I sent the content-type and can I set
it only for a section?
> -Original Message-
> From: Mystik Gotan [mailto:[
Please disregard, after a day of hair-pulling and hacking I managed to
figure it out.
Dave C.
-Original Message-
From: Dave Chappell [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 11:52 AM
To: [EMAIL PROTECTED]
Subject: Formats
Attached is one of a few (work in progre
[EMAIL PROTECTED]
--
Bob Erinkveld (Webmaster Insane Hosts)
www.insane-hosts.net
MSN: [EMAIL PROTECTED]
From: "NYIMI Jose (BMB)" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]>
Subject: RE: Searchable archive?
Date: Wed, 11 Dec 2002 18:34:41 +0100
An other opt
This works where I am at, you could give it a try
-Original Message-
From: Adam Wilson [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 10, 2002 11:27 AM
To: [EMAIL PROTECTED]
Subject: include .pl in html
Hi,
can anyone help me, i want to include the ouput of a perl file within an
h
In a message dated 12/11/2002 12:27:41 PM Pacific Standard Time,
[EMAIL PROTECTED] writes:
> > If it's on the front, it won't remove it because it doesn't have a
> preceeding
> > / in that case.
>
> 'm confused...according to your first post:
I apologize for the confusion, that was in response
Hi friends.
I'd like to know how can I play a sound from a perl script, i mean when i
need.
Thanks a lot.
Atentamente
Sr. Jose Vicente Paredes Loor
Dpto. Tecnico ESPOLTEL S.A.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Paul,
>From what little I have learned of Perl, no. It knows nothing about
HTML. It will write whatever you tell it to. If you happen to tell it
to write something that is in correct HTML format, you can use a web
browser to view the resulting file. The purpose of the cgi.pm module
is to help
On Wed, Dec 11, 2002 at 03:34:07PM -0500, Paul Kraus wrote:
> You can do this?
No.
> Perl will output the text to a file using html? Meaning
> that just the text as it should be and not the tags will print? Cool :)
> I did not know that. Where would I sent the content-type and c
Mystik,
Thanks, but that's not what I'm looking for. That's the first archive
of this group I found. You can get a list of threads or a list of
postings arranged by date, but I don't see a way to type in, say,
"regular expression" and get back all of the posts that contain the
phrase "regular ex
perfect thanks. That html message through me for a loop :)
> -Original Message-
> From: Paul Johnson [mailto:[EMAIL PROTECTED]] On Behalf Of Paul Johnson
> Sent: Wednesday, December 11, 2002 4:02 PM
> To: Paul Kraus
> Cc: 'Mystik Gotan'; [EMAIL PROTECTED]
> Subject: Re: Centered Justified
> I apologize for the confusion, that was in response to Frank's suggestion
> that didn't have the leading '/' question-marked.
Sorry...I misunderstood your OP...here is a solution that should work
$list =~ s!(/)?\b$name\b(/)?!$2 ? ($1||'') : ($2||'')!e;
Tanton
--
To unsubscribe, e-mail: [EM
From: Rob Richardson <[EMAIL PROTECTED]>
> I am a Perl newbie, but I am employed as a Visual C++ and Visual Basic
> programmer. I'm having trouble figuring out what your construct is
> doing. For reference, here it is:
>
> > @website[
> > map $_->[0],
> > sort { $b->[1]
On Wed, Dec 11, 2002 at 11:31:25AM -0800, Rob Richardson wrote:
> Paul,
Hello Rob,
> I am a Perl newbie, but I am employed as a Visual C++ and Visual Basic
> programmer. I'm having trouble figuring out what your construct is
> doing. For reference, here it is:
>
> > @website[
> > m
Hi, Mark, :)
On Wed, 11 Dec 2002 [EMAIL PROTECTED] wrote:
> I have a list of names, separated by the '/' character in a
> variable, $list, and a name in the variable $name. If the name
> appears in the list, I want to remove it and clean up $list. It
> takes me 4 calls to s///, and it looks clu
The only note would be that Jenda use alpha numeric data(a,b,c) and
referenced <=> which is numeric( where cmp does the alphanumeric ) within
the sort routine. Just a heads up.
Wags ;)
-Original Message-
From: Jenda Krynicky [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 11
I would like to write a perl script for windows that in the right situation
fires off another program, the problem is I can't get it to work using
system or exec calls. The file is in the program files directory I tried
system("c:\program files\etc...") and some variations but I can't get it to
wo
On Wed, Dec 11, 2002 at 10:52:53PM +0100, Jenda Krynicky wrote:
> From: Rob Richardson <[EMAIL PROTECTED]>
> >
> > > @website[
> > > map $_->[0],
> > > sort { $b->[1] <=> $a->[1] }
> > > map [ $_, $array[$_] ],
> > > 0 .. $#array
> > > ] =
From: "Wagner, David --- Senior Programmer Analyst --- WGO"
<[EMAIL PROTECTED]>
> The only note would be that Jenda use alpha numeric data(a,b,c) and
> referenced <=> which is numeric( where cmp does the alphanumeric )
> within the sort routine. Just a heads up.
You got
From: Ken Lehman <[EMAIL PROTECTED]>
> I would like to write a perl script for windows that in the right
> situation fires off another program, the problem is I can't get it to
> work using system or exec calls. The file is in the program files
> directory I tried system("c:\program files\etc...")
Paul Kraus wrote:
>
> I am declaring my constants like this.
> use constant SOURCE => "/path/folder/"
> Now how would I use this constant is a print statement or any statement
> for that matter.
> print "$SOURCE" does not work and of course print "source" will not
> work.
The constant pragma crea
Gidday All,
I have written a perl cgi mailing list subscription application.
How do I preserve funny characters in email addresses for example
one subscriber's email address is
sorcha.o'[EMAIL PROTECTED]
but when written to the textfile where I store subscribers names it is written as
[EMAIL
I believe there are no multi-line comments in Perl. Do any of you have a
good hack to fake these?
Thanks
Matt
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Rob Richardson wrote:
>
> Thanks, but that's not what I'm looking for. That's the first archive
> of this group I found. You can get a list of threads or a list of
> postings arranged by date, but I don't see a way to type in, say,
> "regular expression" and get back all of the posts that contai
Looking for a simple method of getting a single process ID (for a
process such as syslogd) and store it in a scalar.
I've found a few methods of doing so but they haven't been pretty.
I'm taking suggestions :)
-gomes
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mai
Check out 'perldoc perlpod' and look for the documentation on =cut. That
shows one way.
-Original Message-
From: Matt Simonsen [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 11, 2002 3:33 PM
To: [EMAIL PROTECTED]
Subject: multi line comments
I believe there are no multi-line com
perldoc perlpod
-Original Message-
From: Matt Simonsen [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 11, 2002 3:33 PM
To: [EMAIL PROTECTED]
Subject: multi line comments
I believe there are no multi-line comments in Perl. Do any of you have a
good hack to fake these?
Thanks
Matt
Hi people ,
I want to modify the headers of the mails in the /var/spool/queue before
delivery, something like an antivirus scan that lock the incoming mail
in the queue until the mail is scanned and then sendmail makes the
delivery ...I have the script to modify the header ... then I can open
t
Ashutosh Jog wrote:
>
> Hello all,
Hello,
> I am a complete newbie and am trying to do a couple of things but was
> not able to. Any assitance is welcome.
>
> If I have a dir structure G:\abc\efg\qrs.txt:
>
> 1) How can I list the entire structure under G:\abc along with all the dirs.
> unde
[EMAIL PROTECTED] wrote:
>
> I have a list of names, separated by the '/' character in a variable, $list,
> and a name in the variable $name. If the name appears in the list, I want to
> remove it and clean up $list. It takes me 4 calls to s///, and it looks
> clunky. I have a feeling that some
Paul Kraus wrote:
>
> How can I justify text. For example lets say I want a 50 character line
> that contains "TITLE", and I want it centered.
> Can this be done with printf?
This is what formating is designed to do.
perldoc perlform
perldoc -f format
perldoc -f write
John
--
use Perl;
prog
Matt Simonsen wrote:
>
> I believe there are no multi-line comments in Perl. Do any of you have a
> good hack to fake these?
http://search.cpan.org/author/KANE/Acme-Comment-1.02/
John
--
use Perl;
program
fulfillment
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mai
On Dec 11, Paul Johnson said:
>On Wed, Dec 11, 2002 at 10:52:53PM +0100, Jenda Krynicky wrote:
>
>> From: Rob Richardson <[EMAIL PROTECTED]>
>> >
>> > > @website[
>> > > map $_->[0],
>> > > sort { $b->[1] <=> $a->[1] }
>> > > map [ $_, $array[$_] ],
>> > >
1 - 100 of 107 matches
Mail list logo