On Sat, May 21, 2005 at 12:11:42AM -0400, Chris Devers wrote:
> On Fri, 20 May 2005, Peter Rabbitson wrote:
>
> > my @lsit = qw(a b c d);
> > my %indexes;
> >
> > my $current_index = 0;
> >
> > foreach my $element (@list) {
> > $indexes{$element} = $current_index;
> > ++ $current_index;
>
On Fri, 20 May 2005, Peter Rabbitson wrote:
> my @lsit = qw(a b c d);
> my %indexes;
>
> my $current_index = 0;
>
> foreach my $element (@list) {
> $indexes{$element} = $current_index;
> ++ $current_index;
> }
Ah. Maybe this?
for (0 .. $#list) {
$indexes{$list[$_]} = $_;
> When perl executes a foreach loop, it creates some kind of array of all the
> iterators and then goes over them one by one. Is the current index pointer
> accessible from inside the loop? I was unable to find anything related in
> perlvar.
I think I should clarify myself a little. Here is an
On Fri, 20 May 2005, Peter Rabbitson wrote:
> >foreach $item ( @list ) {
> > sub( $item );
> >}
> >
>
> Are you sure this is not a typo?
Sorry, I didn't mean that literally, I was just trying to stub in
an indicator for "do something useful with $item". In hindsight,
foreach $i
>foreach $item ( @list ) {
> sub( $item );
>}
>
Are you sure this is not a typo? I've never seen a sub statement taking a
list argument... Besides this is what I get if I run it anyway:
[EMAIL PROTECTED]:~$ cat 123
@list = qw(a bc c);
foreach $item ( @list ) {
sub( $item );
On Fri, 20 May 2005, Peter Rabbitson wrote:
> When perl executes a foreach loop, it creates some kind of array
> of all the iterators and then goes over them one by one. Is the
> current index pointer accessible from inside the loop? I was
> unable to find anything related in perlvar.
I think you
Hello,
When perl executes a foreach loop, it creates some kind of array of all the
iterators and then goes over them one by one. Is the current index pointer
accessible from inside the loop? I was unable to find anything related in
perlvar.
Thanks for the input
Peter
P.S. I know it is trivi
Hi,
I have a piece of code which generates array of arrays which then is used to
call the GD::Graph::Boxplot...
For some reasons, I would have elements that is defined but has not value. I
have been going thru the code to see if I had accidentally assigned null values
or if I had accidentally
I know this has been asked for millions of time, but I searched google
for the entire day but did not get an answer, instead I found millions
of ppl who have the same problem as I am. The problem is simple:
1. The same code runs well on command line
2. When Running on Tomcat, the html file gives su
Am Freitag, 20. Mai 2005 02.52 schrieb Randal L. Schwartz:
> > "Charles" == Charles K Clarkson <[EMAIL PROTECTED]> writes:
>
> Charles> So what should be written there? How does the OP untaint data
> properly?
> There is never a general answer to that question. "data" doesn't have
> an "
Am Freitag, 20. Mai 2005 01.24 schrieb Randal L. Schwartz:
> > "John" == John Doe <[EMAIL PROTECTED]> writes:
>
> John> Imagine the above tainted() without the '#' in the evaled string, and
> $data John> contains 'system ("rm -rf;")':
>
> John> 1. $nada would be executed
> John> 2. the quotes a
All,
It has been some time since I posted, mainly because I do not have many Perl
projects, but as always I am turning to you all for your infinite wisdom. I
have written a web-based script that will promote files from a source server
to a destination server utilizing rsync. I would like to add
> Hi All,
>
> What are the necessary settings required in httpd.conf to use perl cgi
> file thru Apache.
>
>
> Thanks in advance
>
>
>
>
Disclaimer:
This message and any attachment(s) contained here are information that is
confidential,proprietary to HCL Technologies and its customers
Nilay Puri, Noida wrote:
> Hi All,
>
> What are the necessary settings required in httpd.conf to use perl cgi file
> thru Apache.
>
>
> Thanks in advance
>
This is really more an Apache question than a Perl question since CGI
can be written in any language, but you can look here:
http://http
Hi All,
What are the necessary settings required in httpd.conf to use perl cgi file
thru Apache.
Thanks in advance
Disclaimer:
This message and any attachment(s) contained here are information that is
confidential,proprietary to HCL Technologies and its customers, privileged
or otherwise
"Because it's up-side down.
Why is that?
It makes replies harder to read.
Why not?
Please don't top-post." - Sherm Pendley, Mac OS X list
Tielman Koekemoer (TNE) wrote:
>
> Thanks all for your input. The File::Tail package works although it
> seems to stop working once I restart the application
On Fri, 20 May 2005 14:37:35 +0530, Ankur Gupta wrote:
>> Hello beginners@perl.org,
>>
>> it is possible to setup somewhere, I want my script dies, if
>> warning occurs.
>
> BEGIN {
> $SIG{__WARN__} = sub{ print STDERR @_; exit 1};
> }
>
> warn "I am going to die\n";
The more modern (la
Ing. Branislav Gerzo [IBG], on Friday, May 20, 2005 at 09:24 (+0200)
thinks about:
IBG> I'd like to create over 10.000 *.lnk files. I didn't find any module
IBG> for this, could someone help me ? (it could be also commandline
IBG> utility ofcourse).
IBG> Also anyone knows, if it is possible to cre
Ankur Gupta [AG], on Friday, May 20, 2005 at 14:37 (+0530) wrote the
following:
AG> BEGIN {
AG> $SIG{__WARN__} = sub{ print STDERR @_; exit 1};
AG> }
AG> warn "I am going to die\n";
AG> I hope you are looking for something like this.
thanks a lot, this is exactly what I wanted.
--
How d
> Hello beginners@perl.org,
>
> it is possible to setup somewhere, I want my script dies, if
> warning occurs.
BEGIN {
$SIG{__WARN__} = sub{ print STDERR @_; exit 1};
}
warn "I am going to die\n";
I hope you are looking for something like this.
--Ankur
--
To unsubscribe, e-mail:
Thanks all for your input. The File::Tail package works although it
seems to stop working once I restart the application writing to the
logfile. I've played around with the settings but I'll have to take it
up with the author.
Thanks again!
-Original Message-
From: Chris Knipe [mailto:[
Hello beginners@perl.org,
it is possible to setup somewhere, I want my script dies, if warning
occurs.
Thanks
--
--. ,-- ,- ICQ: 7552083 \|||/`//EB: www.2ge.us
,--' | - |--IRC: [2ge](. .),\\SN: 2ge!2ge_us
`+==+=+===~ ~=-o00-(_)-00o-==
Hi All,
I think I found the answer (checking at previous
posts), I think I am going to use
Spreadsheet::WriteExcel.
Thanks,
Alok
--- Alok Bhatt <[EMAIL PROTECTED]> wrote:
> Hi All,
>
> I am writing a script (needless to mention that it
> is
> in perl :)), that would read an excel file and sav
Hi All,
I am writing a script (needless to mention that it is
in perl :)), that would read an excel file and save a
copy of one of the sheet as another excel file and do
processing on it. (Adding formats..etc). Can u please
tell me which would be the best module to handle this.
I have searched th
Hi beginners@perl.org,
I'd like to create over 10.000 *.lnk files. I didn't find any module
for this, could someone help me ? (it could be also commandline
utility ofcourse).
Also anyone knows, if it is possible to create *.lnk files relative to
original file? ("../../abc/orig.exe")
Thanks for an
25 matches
Mail list logo