RE: Multiple values and regex issue

2001-08-13 Thread Bradley M. Handy
http://search.cpan.org/search?module=CGI Brad Handy --www.jack-of-all-trades.net [EMAIL PROTECTED] -Original Message- From: Teresa Raymond [mailto:[EMAIL PROTECTED]] Sent: Monday, August 13, 2001 12:48 PM To: Moon, John Cc: [EMAIL PROTECTED] Subject: RE: Multiple values and regex

OO problem

2001-08-13 Thread Matthias Eichner
Hello, I created two classes, class1 and class2. In a method (m1) of class 1 I instanciate an object of class2 and want to access a method (m2) of this class (class2), But I always get an error that the object method (m2) cannot be located via package class2: Can't locate object method new

help on perl dbi and dbd:mysql

2001-08-13 Thread spartan
I am beginner in perl. i needed to connect the perl programs to mysql database. Therefore I downloaded dbi and dbd:mysql (actually it was mysql-msql modules). I am finding it difficult to compile and run both dbi and dbd:mysql module. By the way I am using Windows 98. When I tried out dbi

Re: help on perl dbi and dbd:mysql

2001-08-13 Thread Jos I. Boumans
if you're on windows, your OS shipped without a c-compiler... for that reason, activestate (www.activestate.com) use 'ppm' - the perl package manager.. which means they already built binaries of the modules you're looking for. i suggest you check that out, it will make your life a LOT easier if

write format, filled fields

2001-08-13 Thread Brodier-Yourstone Philippe
Hello everybody, In the example script below, I'd expect to see 3 lines of text appearing when I use the 'write' command but I only see the first two (123 followed by 456). I know that as much as possible is read from the variable before filling and printing a field (as many words or as many

Re: Displaying 10 jobs per page worries...

2001-08-13 Thread Michael Fowler
On Mon, Aug 13, 2001 at 03:25:59PM +0930, Daniel Falkenberg wrote: The following sub will create a hyperlink when the amount of jobs in my PostgreSQL database reaches over 10 jobs. The hyperlink is a Perl sub which shows the next amount of jobs in the database. I want to only show the next

Re: Newbie needs help with cgi/perl/forms (Thank you)

2001-08-13 Thread Candyban
Birgit Kellner [EMAIL PROTECTED] wrote in message news:1137665400.997570078@[10.0.0.140]... --On Samstag, 11. August 2001 14:09 +0200 Candyban Thank you verry much. It seem to work. Although my @filenames; foreach (@names) { #for each name in the query string if (param('$_') eq on) { #note the

Re: SMTO Socket Connection

2001-08-13 Thread Maxim Berlin
Hello Joel, Monday, August 13, 2001, Joel Divekar [EMAIL PROTECTED] wrote: JD Hi Friends JD Friday evening I heard a New that there is a change of MTA on our JD WebServer. And then all my Perl scripts running on our WebServer refuse to JD send me any stats / logs by email. And this gave me a

Re: Not working in Netscape, working in IE

2001-08-13 Thread Maxim Berlin
Hello Rahul, Monday, August 13, 2001, Rahul Garg [EMAIL PROTECTED] wrote: RG The problem goes like this- RG value of $mailids is coming from previous perl script RG if($emailids eq ' ' || $emailids eq '@' || $emailids eq '.' || $emailids !~ /..+/ ) RG { RG print enter; RG Content-type :

If statements

2001-08-13 Thread mrhate
Hey all, I just started learning Perl yesterday and I've already gotten pretty far in my first program. My question is... well... here's the situation. The first part of my program asks if the user has a current login on the program. If they don't, then the program goes on, if they do, it

Re: If statements

2001-08-13 Thread Jos I. Boumans
cute nick btw. take a look at http://japh.nu there's a tutorial on loops and blocks in the tutorial section.. it should answer your question. hth, Jos Boumans Hey all, I just started learning Perl yesterday and I've already gotten pretty far in my first program. My question is... well...

how does 1 while $scalar =~ s/(%A .*)\n%A /$1\;/g; work?

2001-08-13 Thread ERIC Lawson - x52010
It does change every instance (except the first) of \n%A in the scalar into a semicolon, given a scalar containing, e.g., %Z 1 %X A %A aauth1 %A aauth2 %A aauth3 %A aauth4 %A aauth5 %T atitle1 %T atitle2 %J ajounral %D adate %V avolume %P apages %K akeys1 %K akeys2 %O aother1 %O aother2

Re: how does 1 while $scalar =~ s/(%A .*)\n%A /$1\;/g; work?

2001-08-13 Thread Jeff 'japhy/Marillion' Pinyan
On Aug 13, ERIC Lawson - x52010 said: It does change every instance (except the first) of \n%A in the scalar into a semicolon, given a scalar containing, e.g., Basically, it scrunches %A this %A that %A those into %A this;that;those My concern is with how it works...not understanding how,

Re: how does 1 while $scalar =~ s/(%A .*)\n%A /$1\;/g; work?

2001-08-13 Thread Jeff 'japhy/Marillion' Pinyan
On Aug 13, Jeff 'japhy/Marillion' Pinyan said: On Aug 13, ERIC Lawson - x52010 said: It does change every instance (except the first) of \n%A in the scalar into a semicolon, given a scalar containing, e.g., Basically, it scrunches %A this %A that %A those into %A this;that;those The logic

Re: how does 1 while $scalar =~ s/(%A .*)\n%A /$1\;/g; work?

2001-08-13 Thread ERIC Lawson - x52010
That's an admirable solution, which I'll be sure to generalize and use in other contexts. Thank you. Given that 1 while ... logic works for my needs here, though, is there a reason I should use the sexeger logic instead? Is the 1 while ... expression more costly? It seems, on the face of it,

Re: how does 1 while $scalar =~ s/(%A .*)\n%A /$1\;/g; work?

2001-08-13 Thread Jeff 'japhy/Marillion' Pinyan
On Aug 13, ERIC Lawson - x52010 said: Given that 1 while ... logic works for my needs here, though, is there a reason I should use the sexeger logic instead? Is the 1 while ... expression more costly? It seems, on the face of it, that the 1 while is more readily decypherable by another

format for code review

2001-08-13 Thread Yacketta, Ronald
Folks, What format should one post code reviews in? attachments? script included in email? url? Please advise -Ron -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

eval

2001-08-13 Thread Ismar . Dupanovic
A rather stupid question but I would appreciate a good answer What is the point of the eval function. What would be a reason to use it. From what I gather it is a function that evaluates a piece of Perl code and returns the exit status of the code. What is the point. Why no just write

Re: format for code review

2001-08-13 Thread Michael Fowler
On Mon, Aug 13, 2001 at 02:50:13PM -0400, Yacketta, Ronald wrote: What format should one post code reviews in? attachments? script included in email? url? It depends on the size of the code. I'd say if it's any more than, say, 100 lines put it on a web site somewhere. Otherwise, include it

echo verbose equiv. in perl?

2001-08-13 Thread Jeff Friesen
Does any one know of something similar to set echo verbose (a unix shell-scripting command) in perl? I know there are many other debugging techniques out there, and I think I have tried them all, but sometimes it would be really convenient for debugging. Another application is sending the

Re: format for code review

2001-08-13 Thread Morbus Iff
And remember, the key to having someone actually read your code is to make it readable; make good use of whitespace and indentation, this isn't an obfuscated Perl contest. I'd also include, with a healthy shout, to comment your own code first. It helps people a lot if we can see what you

Re: eval

2001-08-13 Thread Paul Johnson
On Mon, Aug 13, 2001 at 03:12:12PM -0400, Bob Showalter wrote: There are two forms of eval. The string form is used to compile code on the fly, which makes perl into a truly dynamic language. Could it have something to do with run-time code generation. ?? Yes, the string

Re: echo verbose equiv. in perl?

2001-08-13 Thread Paul Johnson
On Mon, Aug 13, 2001 at 12:27:45PM -0700, Jeff Friesen wrote: Does any one know of something similar to set echo verbose (a unix shell-scripting command) in perl? I know there are many other debugging techniques out there, and I think I have tried them all, but sometimes it would be really

help with multiple selections

2001-08-13 Thread John
Please to be helping me, dank u, dank u, but on a more serious note, I am struggling to accomplish one feature of my web currently. I am querying how to associate the qty11820 with another line in a table by the name 11820, as my information does not cross lines correctly, well, it prints all

Tertiary Operator Question

2001-08-13 Thread David Rankin
Hi Everybody, I'm having trouble figuring out the way the tertiary operator evaluates and returns data. Here's what I don't get . . . If I do this: #!/usr/bin/perl -w use strict; my $num=3; $num==3 ? print Num equals 3 : print Num does not equal 3; I get what I'd expect, Num equals 3 gets

Re: Tertiary Operator Question

2001-08-13 Thread Ken
When I run the line outputted from the Deparse inplace of his original code I get errors! What's up with that? #!/usr/bin/perl -w use strict; my $num=3; my $nextnum; ((($num == 3) ? ($nextnum = 4) : $nextnum) = unknown); print $nextnum; - Original Message - From: Paul Johnson [EMAIL

Help needed on Regular Expression

2001-08-13 Thread Hanming Tu
Hi All, I am writing a program to display POD, functions, Perl FAQ, and programs and want to impement two rules for the input: 1. it is Perl module names if the input starts with words or '-m'; 2. it is Perl function, FAQ, or program name if it starts with -f, -q, or -p respectively. Here is

Re: Tertiary Operator Question

2001-08-13 Thread David Rankin
Thanks! I've been trying to figure that out for hours! Now I actually get it! -Dave On Tue, 14 Aug 2001 00:09:59 +0200, Paul Johnson wrote: On Mon, Aug 13, 2001 at 05:50:14PM -0400, David Rankin wrote: #!/usr/bin/perl -w use strict; my $num=3; my $nextnum; $num==3 ? $nextnum=4 :

Re: Tertiary Operator Question

2001-08-13 Thread Paul Johnson
On Mon, Aug 13, 2001 at 05:50:14PM -0400, David Rankin wrote: #!/usr/bin/perl -w use strict; my $num=3; my $nextnum; $num==3 ? $nextnum=4 : $nextnum=unknown ; print $nextnum; It prints unknown. I'd expect it to print 4 because $num==3 would evaluate to true. You're being hit by

Re: Games in PERL ?????

2001-08-13 Thread Troy Denkinger
Randal, On Monday 13 August 2001 14:10, Randal L. Schwartz wrote: Troy I'm not sure I would call Perl a mixture of many languages, though it has Troy adopted features from other languages. And calling Perl an OOP-based Troy language might be overstating it, though I do like Perl's OOP

Re: Games in PERL ?????

2001-08-13 Thread Randal L. Schwartz
Troy == Troy Denkinger [EMAIL PROTECTED] writes: Troy I'm not sure I would call Perl a mixture of many languages, though it has Troy adopted features from other languages. And calling Perl an OOP-based Troy language might be overstating it, though I do like Perl's OOP features, Troy such as

Split question

2001-08-13 Thread Scott and Kristin Seitz
I have a delimited text file with a vertical bar (|) as the column delimiter. When I execute the following statement... @Line = split(/\|/, $_); ...I get the expected results. When I execute the following... $CharSep=\|; @Line = split(/$CharSep/, $_); ...the file seems to break at every

Re: Split question

2001-08-13 Thread Shane Laffin
Scott, The problem is that | is a pattern metacharacter, and still needs to be escaped. try: my @arr = split(/\Q$CharSep/, $_); # I have a delimited text file with a vertical bar (|) as the column delimiter. When I execute the following

Re: Split question

2001-08-13 Thread Jeff 'japhy/Marillion' Pinyan
On Aug 13, Scott and Kristin Seitz said: $CharSep=\|; The double quoted string \| is still just |. Use single quotes or the quotemeta() function. -- Jeff japhy Pinyan [EMAIL PROTECTED] http://www.pobox.com/~japhy/ RPI Acacia brother #734 http://www.perlmonks.org/