On Saturday, August 3, 2002, at 08:43 AM, David Farnum wrote:
>Hello i have been learning perl for about 1 year now on my own. I have
> been learning C++, Java, HTML, Visual Basic, and C# is school. And the
> one thing i want to say is that perl is the best. Everytime I find myself
> wri
On Saturday, August 3, 2002, at 06:52 AM, drieux wrote:
>
> On Saturday, August 3, 2002, at 08:43 , David Farnum wrote:
> [..]
>> I am learning Object oriented programming and perl Tk right now. I hope
>> to move on to regular expretions soon. Well that is it just wanted to
>> say I would ra
On Wednesday, July 10, 2002, at 09:05 AM, Jeff 'japhy' Pinyan wrote:
> On Jul 10, bob ackerman said:
>
>> and, as someone pointed out, this does work:
>> $x = ['abc','def','ghi'];
>> print @$x[2]."\n"; # prints &
On Wednesday, July 10, 2002, at 09:39 AM, Jeff 'japhy' Pinyan wrote:
> On Jul 10, George Schlossnagle said:
>
>> Am I alone in thinking that $x->[2] is much more readable that @$x[2]
>> or $$x[2]?
>
> No; I always use the $ref->... syntax, unless I'm golfing.
>
>> @b[2] is an array slice with
On Wednesday, July 10, 2002, at 09:29 AM, George Schlossnagle wrote:
>> and, as someone pointed out, this does work:
>> $x = ['abc','def','ghi'];
>> print @$x[2]."\n"; # prints 'ghi'
>
>
> Am I alone in thinking that $x->[2] is much more readable that @$x[2]
> or $$x[2]?
i was only sa
On Wednesday, July 10, 2002, at 01:31 AM, Janek Schleicher wrote:
> Shawn wrote at Wed, 10 Jul 2002 09:59:54 +0200:
>
>> I think what you are looking for is:
>> $avg_resp_time->[0]
>>
>> if you want to have the '@' at the front, I think you would need
>> something like this:
>> @{$avg_resp_t
On Monday, July 8, 2002, at 02:03 PM, Kevin Pfeiffer wrote:
> bob ackerman writes:
> [...]
>> so:
>> s|{(.*?)}|$1=~ tr///|xg;
>
> I'm trying to test this myself on a string (rather than $_), but don't
> understand how to use tr/// on $1 and then pl
On Sunday, July 7, 2002, at 10:03 PM, bob ackerman wrote:
>
> On Monday, July 8, 2002, at 12:55 AM, Todd Wade wrote:
>
>>
>> "David Carpenter" <[EMAIL PROTECTED]> wrote in message
>> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>>
&
On Monday, July 8, 2002, at 12:55 AM, Todd Wade wrote:
>
> "David Carpenter" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>
>> I have a text file with occasional strings enclosed in braces:
>> kdkdkiwiwdkdkdk {iwidkwidkw} kdkdkdwiwiwkdkdk . . .
>>
>> I wou
On Monday, July 8, 2002, at 12:46 AM, Todd Wade wrote:
>
> "Patricia Hinman" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>> Does anyone know of a routine that will sort arrays by
>> size. I need to sort any number of given arrays, and
>> operate on the l
On Sunday, July 7, 2002, at 05:47 AM, David T-G wrote:
> Hi, all --
>
> It must still be early, because I just don't get this.
>
> Given the snippet
>
> sub setpath(my $shelltype)
> {
> my ($setenv,$equals) ;
> # $_[0] =~ /tcsh/ && $setenv = "setenv" ;
> # $_[0] =~ /tcsh/ && { $se
On Friday, July 5, 2002, at 02:32 PM, Connie Chan wrote:
> Try Cookies.pm,
> $cookie_jar->accept_cookies($bool);
> document at
> http://search.cpan.org/doc/ILYAM/HTTP-
> WebTest-1.99_07/lib/HTTP/WebTest/Cooki
> es.pm
accept_cookies($optional_accept_cookies)
Enables or disables receipt of cooki
On Wednesday, July 3, 2002, at 01:17 PM, drieux wrote:
>
> volks,
>
> http://www.wetware.com/drieux/pbl/perlTrick/CBO/PingIt/
>
> as a way to look at evolving code upward from the
> simple idea
oops:
One could in theory just take this Forth Script and "go" - modify it as
appropriate
On Sunday, June 30, 2002, at 08:37 AM, drieux wrote:
>
> On Saturday, June 29, 2002, at 11:07 , George Georgalis wrote:
>
>> Huh? Why not look it up in a dictionary? ... oh I guess you said that to
>> :)
>
> part of the problem is that there are many
> dictionary routines that would consider
>
On Wednesday, June 26, 2002, at 08:50 AM, drieux wrote:
> { embedded in that is - so how should I be making perl modules
> in a standard way that will be easiest for the perl community. Trust
> me that question will come - since you started with the right form
> of "I found modules I can us
On Wednesday, June 26, 2002, at 08:48 AM, Shishir K. Singh wrote:
>> $out = $1 if ($in =~ /\((.*?)\)/);
> Nope..won't work..I take it back!!
>
looks ok to me. except it adds extra strokes to previous answer.
what do you think is wrong with it?
On Tuesday, June 25, 2002, at 04:59 AM, John W. Krahn wrote:
> Will Shiver wrote:
[...]
> perl -lane'$a{$F[0]}++or$a=qw/box robo rain/[$b++%3];print"$F[0] $a"'
> yourfile.txt
>
>
> John
sure. almost obviously.
but...
i assume things like '$a' ,'$b', and '$F' come from those switches, so
on
On Monday, June 24, 2002, at 01:48 PM, drieux wrote:
>
> On Monday, June 24, 2002, at 01:34 , bob ackerman wrote:
> [..]
>> yes but there is not a place to easily grasp the idea of using h2xs.
>> a little holdhanding would help.
> [..]
>
> thanks for keeping me h
On Monday, June 24, 2002, at 01:00 PM, drieux wrote:
>
> On Monday, June 24, 2002, at 11:30 , Theresa Mullin wrote:
> [..]
>> use Test;
>>
> [..]
>>
>>
Here is module Test:
>>
>> #!/usr/bin/perl
>>
>> ### Program Name: Test.pm
>> ### Created By:Theresa Mullin
>> ### Date: 5/20
start the file with:
package utils;#or whatever name you want
put your subroutines in the file:
sub foo() # for instance
{
}
end the file with:
1; # package should return true
then in other files, to access:
use utils; # at top of file
and:
foo(); # to acces
On Friday, June 21, 2002, at 09:15 AM, drieux wrote:
>
> On Friday, June 21, 2002, at 08:38 , Nigel Peck wrote:
> [..]
>> Or is it d, something I shouldn't be wasting my time thinking about so
>> move on (boring git).
>
> IT IS A SCARY PLACE OUT THERE!!!
>
> ciao
> drieux
>
or 'out there' is
On Tuesday, June 11, 2002, at 03:02 PM, David T-G wrote:
> Bob --
>
> ...and then bob ackerman said...
> %
> % i am trying to login to DI-704 DLink router.
>
> Why was this in the "killing idle users" thread instead of in your
> "get external IP from D-
On Tuesday, June 11, 2002, at 10:55 PM, Todd Wade wrote:
> Right, but is the document you are trying to get the ip from called
> status.htm?
i have changed my strategy since then. the python posted to the /cgi-
bin/logi file first to login.
then called the status.htm to get data. again, i say,
i am trying to login to DI-704 DLink router.
i have python code that works. i want to do it in perl.
the params below come from the python code.
i get a 'Failed to login' when i run the code below.
use LWP::UserAgent;
my $ua = new LWP::UserAgent;
my $req = HTTP::Request->new(POST => 'http://192.
On Monday, June 10, 2002, at 09:02 PM, drieux wrote:
>
> On Monday, June 10, 2002, at 07:29 , bob ackerman wrote:
>
>>
>> note the ip was slightly different for linksys. it was 192.168.1.1.
>> above is the ip i use to manually login. the html file is what the
>
On Monday, June 10, 2002, at 09:48 PM, Todd Wade wrote:
>
> "Bob Ackerman" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>>
>
>> i can't quite figure out how to do this in perl. i have:
>> us
On Monday, June 10, 2002, at 06:30 PM, Geoffrey F. Green wrote:
> On 6/10/02 8:55 PM, "bob ackerman" <[EMAIL PROTECTED]> wrote:
>
>> # Fetch the page
>> $admin = ARGV[0];#password
>> print $admin,"\n";
>> my $ua = LWP::User
On Monday, June 10, 2002, at 05:26 PM, Todd Wade wrote:
> Bob Ackerman wrote:
>
>> my box is behind a D-Link router 704.
>> The router gets its ip from my isp using dhcp.
>> anyone know how to get that external ip from the router?
>> is any module designed to f
On Monday, June 10, 2002, at 11:57 AM, Jeff 'japhy' Pinyan wrote:
> On Jun 10, bob ackerman said:
>
>> On Monday, June 10, 2002, at 11:23 AM, aman cgiperl wrote:
>>
>>> $MSG is a link http://www.foo.com/dpt/index.html
>>>
>>> Is there an
On Monday, June 10, 2002, at 10:49 AM, drieux wrote:
>
> On Monday, June 10, 2002, at 10:35 , bob ackerman wrote:
>
>> my box is behind a D-Link router 704.
>> The router gets its ip from my isp using dhcp.
>> anyone know how to get that external ip from the rout
On Monday, June 10, 2002, at 11:23 AM, aman cgiperl wrote:
> $MSG is a link http://www.foo.com/dpt/index.html
>
> Is there anything else other than EOF, that can cause a while loop to exit
> when reading file?
there is something that will stop the substitution - a slash in $MSG.
you could use
my box is behind a D-Link router 704.
The router gets its ip from my isp using dhcp.
anyone know how to get that external ip from the router?
is any module designed to find your external ip when you are on a lan?
router is admined from a web page, so i guess it is possible to using LWP
(or some
On Monday, June 3, 2002, at 10:45 AM, bob ackerman wrote:
>
> On Monday, June 3, 2002, at 10:37 AM, Jeff 'japhy' Pinyan wrote:
>
>> On Jun 3, bob ackerman said:
>>
>>>> @ARGV = "< $filename" if $opt_f;
>>>
>>> why &
On Monday, June 3, 2002, at 10:37 AM, Jeff 'japhy' Pinyan wrote:
> On Jun 3, bob ackerman said:
>
>>> @ARGV = "< $filename" if $opt_f;
>>
>> why '<' ? isn't '$filename' enough for get '<>' to open
On Monday, June 3, 2002, at 09:27 AM, Jeff 'japhy' Pinyan wrote:
> On Jun 3, Balint, Jess said:
>
>> Hello all. I am working on my script, and I would like to be able to use
>> STDIN as a filehandle input unless a filename is specified. I have used
>> the
>> getopt for the filename, let's say
On Thursday, May 30, 2002, at 02:53 PM, bob ackerman wrote:
>
> On Thursday, May 30, 2002, at 11:20 AM, David Gray wrote:
>
>>>>> while () {
>>>>> chomp;
>>>>> s/^\s+//;
>>>>> next if (m/^$/ || (1 .. /
On Thursday, May 30, 2002, at 11:20 AM, David Gray wrote:
while () {
chomp;
s/^\s+//;
next if (m/^$/ || (1 .. /^NPROC/));
>>>
>>> what does the range thing do?
>>> wouldn't just ... || /^NPROC/ be enough?
>>
>> ok. opposite sense: || ! /^NPROC/
>
> So that wo
On Thursday, May 30, 2002, at 09:44 AM, bob ackerman wrote:
>
> On Thursday, May 30, 2002, at 07:31 AM, Sudarsan Raghavan wrote:
>
>> "Kipp, James" wrote:
>>
>>> I am reading output from a pipe to a command called 'prstat' (like top)
>>
On Thursday, May 30, 2002, at 07:31 AM, Sudarsan Raghavan wrote:
> "Kipp, James" wrote:
>
>> I am reading output from a pipe to a command called 'prstat' (like top).
>> just wanted to get some ideas on the best way to capture the data i am
>> looking for. below is an example of the output:
>
>
On Sunday, May 26, 2002, at 09:53 PM, Schuessler, Robert BTB TKY wrote:
> Hello,
>
> I want to use grep to get a list of files into @files. Here's what it
> looks
> like now:
>
> $sender = "CHAS";
> $asofdate = "20020401";
>
> @files = `grep -sl $sender /home/data/*`;
> print @files;
>
>
>
>
On Saturday, May 25, 2002, at 12:00 PM, Phil Dobbin wrote:
> On 25/5/02 at 11:46, [EMAIL PROTECTED] (bob ackerman) wrote:
>
>>
>> On Saturday, May 25, 2002, at 11:41 AM, Phil Dobbin wrote:
>>
>>> I'm trying to install Bundle::DBI and CPAN gives me thi
On Sunday, May 19, 2002, at 10:58 PM, [EMAIL PROTECTED] wrote:
> Hello, All:
>
> I'm using DBI.pm to interact with flat-file database and want to add a new
> column to the database. Is there an SQL statement for such a task or do I
> need to transfer the contents of the file to another file and
On Friday, May 17, 2002, at 05:35 PM, drieux wrote:
>
> On Friday, May 17, 2002, at 05:16 , Mark Anderson wrote:
>
> we all agree that this is a 'bad' idea and that
> timothy has the right solution...
> now for the troubling bits...
>
>
>>> What's the best way to do this? I've tried
>>>
>>>
On Friday, May 17, 2002, at 09:40 AM, Batchelor, Scott wrote:
> /([^a-zA-Z])\1/
did you mean to be checking for repeating non-alpha characters?
if you are testing with repeating alpha characters, that test won't catch
it.
On Friday, May 17, 2002, at 08:40 AM, VINCENT BUFFERNE wrote:
> I am using vec($foo1, $foo2, $foo3). It seems that the value of $foo3 is
> limited to 2048 (with perl 5.004 or perl 5.6.1). Is it possible to use
> wider
> values: up to 60,000 ???
are you sure it is limited? i don't have a test
On Thursday, May 16, 2002, at 04:12 PM, Daniel J. Rychlik wrote:
> Hello,
>
> Im working on running this $sqlstatement for work purposes. My =
> $txtAgentID='skraal'; will be an array of 13 agents. (I was just trying
> to get this to run for one agent) The error message Im getting is at
> th
On Thursday, May 16, 2002, at 01:55 PM, Kevin O wrote:
> Hello all,
>
> I need to insert a lot of data into a mysql table. Know that I can do it
> like this example:
>
>
>
> my $sth = $dbh->prepare(q{
>INSERT INTO sales (product_code, qty, price) VALUES (?, ?, ?)
> }) or die $dbh->errstr
On Monday, May 13, 2002, at 10:40 AM, Todd Wade,,,Room 108 wrote:
> Bob Ackerman wrote:
>
>>
>> this one wins the prolix award of the solutions we have seen today.
>> we dare a non-perl programmer to believe this could mean something.
>> I'm not sure i be
On Sunday, May 12, 2002, at 11:08 PM, Todd Wade wrote:
>
> "JosÈ nyimi" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
>> The Perl slogan is: "There Is More Than One Way To Do It".
>>
>> I'm interested to see how you will do the small convertion below.
>
> T
On Sunday, May 12, 2002, at 09:38 PM, Bill Lyles wrote:
> Huh?
>
i think you are calling an html file that gets the input and posts to this
cgi script.
so drieux is confused when you say the whole script. it is the whole cgi,
but there is an html file that does the post.
> - Original M
On Sunday, May 12, 2002, at 06:13 PM, Bill Lyles wrote:
> if ($email !~ /.+\@.+\..+/) {
we assume you are assigning something to $email
and the email address with the '@' is single quoted so it doesn't try to
interpolate.
(or you are escaping the '@' in a double quoted string.)
otherwise the
On Saturday, May 11, 2002, at 05:35 PM, drieux wrote:
>
> On Saturday, May 11, 2002, at 01:12 , drieux wrote:
>
>>
>> thought I would formalize the play a bit, and see
>> what folks think about:
>>
>> http://www.wetware.com/drieux/CS/lang/Perl/Beginners/RegEx/HowPatternsEvolve.
>> txt
>
>
> htt
On Saturday, May 11, 2002, at 01:12 PM, drieux wrote:
> http://www.wetware.com/drieux/CS/lang/Perl/Beginners/RegEx/HowPatternsEvolve.
> txt
Lo! another wapped url which readers will chop off and get wrong. urk.
how Do we avoid that?
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additiona
On Friday, May 10, 2002, at 08:09 AM, Nikola Janceski wrote:
> tie %ANSWER "/dev/brain";
> print %ANSWER{$question}, "\n";
> ^D
> Most of it.
shouldn't that be:
print $ANSWER{$question},"\n";
>> -Original Message-
>> From: drieux [mailto:[EMAIL PROTECTED]]
>> Sent: Friday, May 10, 20
On Tuesday, May 7, 2002, at 11:07 AM, drieux wrote:
>
>
shouldn't that be:
> ciao
> drieux
>
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
On Tuesday, May 7, 2002, at 09:03 AM, Timothy Johnson wrote:
> Oops! Looks like I forgot the 'm'. That should be
> http://www.rocketaware.com/perl/perlfaq5/How_can_I_make_a_filehandle_loc
> a.htm
you didn't forget it the first time. the letter 'm' had wrapped to the
next line and wasn't se
On Friday, May 3, 2002, at 12:39 PM, Jason Frisvold wrote:
> Let's see if I can explain what I'm trying to do before I toss code
> out... I have a database with several columns of data. I want to fetch
> all the pertinent info into a single array of arrays and then work on
> each row of the d
On Thursday, May 2, 2002, at 02:45 AM, Paul Weissman wrote:
>
> what i'm trying to do is open a binary file and read from it...
>
> ---\
>
> open ( FD, $filename );
> binmode ( FD );
>
> #read two bytes
> while (read(FD, $buf, 2)) {
> # hopefully print the hex value of two bytes
> print hex($
On Wednesday, May 1, 2002, at 03:43 PM, Ron wrote:
> Hello Greg
>
> This is a simple method that may work.
>
> while ( my @data= $cursor->fetchrow_array ) {
> $idnum = $row[0];
> $username = $row[1];
> $email = $row[2];
> $code= $row[3];
>
> print "$idnum $username $email $code ";
> }
On Wednesday, May 1, 2002, at 02:55 PM, drieux wrote:
>
> On Wednesday, May 1, 2002, at 02:47 , Greg D. wrote:
>
>> Hi,
>>
>> Is there any way i can split an array that contains information that i
>> got
>> from the mysql database?
>>
>> here's the code:
>>
>> while(my @data = $sth->fetchrow_a
On Tuesday, April 30, 2002, at 04:07 PM, Johnson, Shaunn wrote:
> Howdy:
>
> I'm looking for examples of how to use element 0
> in one array as a search pattern and looking in
> other arrays for that pattern. Here's what I have
> so far ...
>
> [snip code]
> #!/usr/bin/perl -w
> use diagnostic
On Tuesday, April 30, 2002, at 04:17 PM, Tor Hildrum wrote:
> First of all, I would just like to apologize for not sending this to the
> CGI-list, but I prefer this list. As this is where I've gotten the best
> help
> in the past. Blame yourself :)
>
> I was reading CGI.pm when I discovered th
On Tuesday, April 30, 2002, at 03:51 AM, [EMAIL PROTECTED]
wrote:
>
> Thats it Thanks Harry understand now..
for completion's sake:
you were asking how to create a variable name programmatically and use it.
$h='0';
$TRY = 'world';
$tryvar = $try.$h; # we have created a new variabl
# handle error
}
this we avoid trying to get the value of an undefined item.
you can do what you want on error - ignore it,print out an error message,
redirect, etc.
> -Original Message-
> From: bob ackerman [mailto:[EMAIL PROTECTED]]
> Sent: Sunday, April 28, 2002
existence.
say
$ref = $cookie{'usertype'};
$val=0;
if ($ref)# or if (defined($ref)) ?
{
$val = $ref->value;
}
else
{
print "cookie 'usertype' doesn't exist";
}
> -Original Message-
> From: bob ackerman [mailto:[EMAIL
On Friday, April 26, 2002, at 11:27 PM, r wrote:
> Goal- look up value in a hash of 3 fields where middle is key field for
> lookup. The build hash from text file part below is working fine.
> Then I read in a transaction file with field $sicode which should
> lookup/chain/match to the key ($si
On Thursday, April 25, 2002, at 05:24 PM, Jeff 'japhy' Pinyan wrote:
> On Apr 25, Bryan R Harris said:
>
>> I'd like to remove all elements in an array that meet a certain criteria
>> without changing their order. I'm sure this gets done all the time, but
>> I'm not sure how to do it...
>
> You
at start of each of my
cgi files.
> -Original Message-
> From: bob ackerman [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, April 25, 2002 7:26 PM
> To: [EMAIL PROTECTED]
> Subject: Re: authentication and user management
>
>
>
> On Thursday, April 25, 2002,
no absolute guarantee.
> -Original Message-----
> From: bob ackerman [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, April 25, 2002 7:26 PM
> To: [EMAIL PROTECTED]
> Subject: Re: authentication and user management
>
>
>
> On Thursday, April 25, 2002, at 10:58 AM, Mat Har
On Thursday, April 25, 2002, at 10:58 AM, Mat Harrison wrote:
> i am building a perl/cookie members system for my site using SSI to check
> if
> a cookie is present (set at login), if not, to redirect to an error page.
> This is my plan:
>
>
> 1. login page. check that the username and passwor
On Tuesday, April 23, 2002, at 03:05 PM, Jonathan E. Paton wrote:
>>> Is there a better way to simplify the syntax when testing for multiple
>>> conditions?
>>
>> Your original code is the proper way to do it. All the other solutions
>> proffered are inferior, IMO.
>
> Use 'or' and 'and' to rem
On Monday, April 22, 2002, at 06:01 AM, [EMAIL PROTECTED] wrote:
> hi
>
> im trying to sort out this sort routine:
>
> the sub by_number_of_citations works
>
> but if i try to make a sort alphabetically, my regex fails?
>
> how should it be done?
>
>
> martin
>
>
>
> # sting to match: 1212Cited
could someone explain how this syntax works?
does the call to member function 'proxy' return the object which is then
used to call function 'uri' which returns the object which is used to call
function 'hi' which returns the object which is used to call method
'result'?
use SOAP::Lite;
print SO
On Friday, April 19, 2002, at 07:18 AM, bernabe diaz wrote:
> Hi everyone,
> could somebody help me with the following problem:
> i have a code something like that
> my $variable = CGI->param('NAME');
> #making connection to database
> .
> my $variable_ =$dbh->q
for integers:
(add one) divide by 2.
$rndup = ($var+1)/2;
On Wednesday, April 17, 2002, at 10:01 AM, Glenn Cannon wrote:
> I am dividing a number by 2. How do I force a round up of the result?
>
> Glenn.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PR
read
now on this list about bidirectional sockets.
> -----Original Message-
> From: bob ackerman [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, April 16, 2002 3:02 PM
> To: [EMAIL PROTECTED]
>
nf file.
usually find it in /etc directory.
> -Original Message-
> From: bob ackerman [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, April 16, 2002 1:13 PM
> To: [EMAIL PROTECTED]
> Subject:Re: Errors Runn
On Tuesday, April 16, 2002, at 10:11 AM, Ho, Tony wrote:
> Hi guys
> I was wondering if you could help me.
> Does anybody know how to write formatted results to a file ?
>
> I am getting the following error :
>
> write() on closed filehandle main::ADDRESSLABEL at ./test.pl line 2785,
> line 5.
On Tuesday, April 16, 2002, at 10:11 AM, Ho, Tony wrote:
> Hi guys
> I was wondering if you could help me.
> Does anybody know how to write formatted results to a file ?
>
> I am getting the following error :
>
> write() on closed filehandle main::ADDRESSLABEL at ./test.pl line 2785,
> line 5.
On Tuesday, April 16, 2002, at 09:05 AM, Anthony Beaman wrote:
> Thanks! I think your advice may apply to the following code that I'm
> having trouble with:
>
> use Win32::NetAdmin;
> $username = Win32::LoginName;
> Win32::NetAdmin::UserGetAttributes("", $username, $password,
> $passwordage, $
On Monday, April 15, 2002, at 08:58 PM, Daniel Falkenberg wrote:
> Hello All,
>
> How would I go about checking to see if a variable contains an @ symbol?
>
> $email = "[EMAIL PROTECTED]";
>
> if ($email ne "@" || $email eq "") {
> print "Please make sure your type your email address in correc
On Monday, April 15, 2002, at 08:58 PM, Daniel Falkenberg wrote:
> Hello All,
>
> How would I go about checking to see if a variable contains an @ symbol?
>
> $email = "[EMAIL PROTECTED]";
>
> if ($email ne "@" || $email eq "") {
> print "Please make sure your type your email address in correc
On Monday, April 15, 2002, at 07:46 PM, Daniel Falkenberg wrote:
> Hey All,
>
> I am just about to go ahead and start validating form data. I was
> thinking about tackling it in the following way...
>
> $data1 = param("data1");
> $data2 = param("data2");
> $data3 = param("data3");
> $data4 = p
On Monday, April 15, 2002, at 02:31 PM, James Taylor wrote:
> I'm sure this is frequently asked, and I am truly sorry if it is, but
> reading through my mail I don't see this question anywhere:
>
> Curious as to how I would go about creating bidirectional sockets, ie.
> client sends informati
ll tell me you don't want to read the whole file in at once :)
that's when you have to do like what i offered the first time.
>> Thanks,
>> Ramesh
>>
>> -Original Message-
>> From: bob ackerman [mailto:[EMAIL PROTECTED]]
>> Sent: Friday, April
On Friday, April 12, 2002, at 07:55 PM, Gabriel Duchateau wrote:
> I am trying to setup a small application with a passwd controlled access.
> I
> need just a little bit of security so I decided to use the crypt function
> on
> perl to encrypt the user passwd. The problem I have is when writi
On Friday, April 12, 2002, at 12:58 PM, David Gray wrote:
>> for e.g :
>>
>> (not showing the new lines..)
>>
>>
>> word1.word1.word1word2word1...word2wor
>> d2word2
>> .
>
> You're gonna want to check out (in the perldoc perlre manpage) (??{ code
> }), which
On Friday, April 12, 2002, at 09:09 AM, Guan Boon Lee wrote:
> I would like to find a word or character in a file and
> replace it with another word or character, while
> leaving others untouched. Currently, I am using the
> following method
>
> #!/bin/perl -Dr -w
> open(FILE,"$ARGV[0]") || di
On Friday, April 12, 2002, at 08:05 AM, Timothy A. DeWees wrote:
> Hello,
>
> I am trying to convert a shell script to perl because I need to do
> some
> binary math, and I want to add more flexibility in general.I'm a bit
> new
> to perl, but here is my question (don't laugh).
>
> I
es) {$max=$_ if($_>$max)}
>
>> -----Original Message-
>> From: bob ackerman [mailto:[EMAIL PROTECTED]]
>> Sent: Thursday, April 11, 2002 5:52 PM
>> To: [EMAIL PROTECTED]
>> Subject: Re: max/min
>>
>&
On Thursday, April 11, 2002, at 01:42 PM, Jeff 'japhy' Pinyan wrote:
> On Apr 11, Bryan R Harris said:
>
>> $someVar = max(@listofvalues);
>>
>> Is there a function in perl like this?
>
> You could use the List::Util module (from CPAN). Or, you could write your
> own:
>
> sub max {
> my
On Thursday, April 11, 2002, at 01:17 PM, Timothy Johnson wrote:
>
> Just for those who haven't figured out why the first example is so useful,
> consider what perl is doing in the following two snippets:
>
> 1
> ==
> open(INFILE,"myfile.txt");
> @file = ;
> foreach(@file){
>do somethin
On Thursday, April 11, 2002, at 11:46 AM, Amerson, Kevin wrote:
> Hello,
>
> How would you put the matches into a comma separated list?
>
if you want to print it out:
print "@data";
if you want to create a single string:
$data = join ',',@data;
or did you have something else in mind?
>
> --
On Thursday, April 11, 2002, at 10:57 AM, wim wrote:
> my $var = "test";
> my $rvar = "\$interface";
>
try:
my $rvar = '\$interface';
so it doesn't look like a variable to be interpolated when you get to the
substitution.
> my $cmd = "int \$interface\n";
>
> print "$var\n";
> print "$cmd\
On Wednesday, April 10, 2002, at 01:34 PM, @fro @ndy wrote:
> Hi,
> Once again i have another problem regarding my message board lol. This
> time the message board is fine but i have made an admin so that it will
> read the contents of a text file where all the entries are printed to and
> d
On Tuesday, April 9, 2002, at 12:29 PM, bob ackerman wrote:
>
> On Tuesday, April 9, 2002, at 11:06 AM, Helen Dynah wrote:
>
>>
>> HI,
>>
>> I have a perl script and I am trying to write another perl script which
>> will open my first perl script, c
On Tuesday, April 9, 2002, at 11:06 AM, Helen Dynah wrote:
>
> HI,
>
> I have a perl script and I am trying to write another perl script which
> will open my first perl script, change the values of some variables, and
> run the script with these new variables. Does anyone know if this is
>
On Tuesday, April 9, 2002, at 10:19 AM, Schroeter, Richard wrote:
> Greetings,
> I am having a problem with Perl providing me the correct date when I
> subtract 86400 from the date. This is only happening when I set the
> computer's system's date to today's date. If I set the system's date to
On Tuesday, April 9, 2002, at 09:39 AM, Kristin A. I. wrote:
> I am trying to indent a scroll-thru menu which has been made into a tree
> using the following database query:
> select dept_id, LPAD(' ',2*(Level-1))||dept_name dept_name
> from depts
> start with dept_id = 1
> connect by
On Monday, April 8, 2002, at 05:10 PM, Bryan R Harris wrote:
> open (FILE, $file) || die("Couldn't open $file: $!\n");
> @_ = ;
> close(FILE);
> while ($_[1] =~ /^[#\n]/) { push(@comments, shift(@_)); }
> print "@comments";
seems unnecessary to create an array then print each element.
just p
1 - 100 of 159 matches
Mail list logo