Re: @UNIQUE=unique(@REDUNDANT);

2004-05-18 Thread Jason Dusek
What modules handle this? I have been digging around in CPAN all day... -- -- Jason Dusek ("`-''-/").___..--''"`-._ -- | `6_ 6 ) `-. ( ).`-.__.`) -- | (_Y_.)' ._ ) `._ `. ``-..-' -- | _.

@UNIQUE=unique(@REDUNDANT);

2004-05-18 Thread Jason Dusek
Hi, Is there an easy way to get all the unique elements of an array? i.e. is there some module or function that does that sort of thing? -- -- Jason Dusek ("`-''-/").___..--''"`-._ -- | `6_ 6 ) `-. ( )

Broke My @INC

2004-05-17 Thread Jason Dusek
Hi List, My @INC is messed up - Perl can't find any modules. If I know the path to a module, is there some kind of quick work around? For those who are curious, I seem to have broken my @INC by installing the ports (I'm on FreeBSD) for Perl 5.6.1 and Perl 5.8.2. -- -- J

Getting the href

2004-05-17 Thread Jason Dusek
Hi Everyone, What is good way to pull the href from a link in html? If I have links like: meow woof moo bark bahh meow bahh moo bark How do I pull just the 'here_kitty' part? -- -- Jason Dusek ("`-''-/").___..--

Ignoring Files With Spaces In Them

2004-05-11 Thread Jason Dusek
(/\.(pro|idl)$/ && !/\w+\s+\w+/) { ## do some fancy stuff } } but the evil files with spaces in their names seem to be slipping through the regexp. Any suggestions? -- -- Jason Dusek ("`-''-/").___..--''"`-._ -- |

Array in a regexp

2004-05-07 Thread Jason Dusek
in my regular expression. What does this? I've tried: @SUFF = (fish,foul); foreach (@ARGV) { print if (/\.(@SUFFIXES)$/); } and also: @SUFF = (fish,foul); foreach (@ARGV) { print if (/\.(@[EMAIL PROTECTED])$/); } but I can't get it to work. --

Taking Over A Server With Regular Expressions

2004-04-27 Thread Jason Dusek
In the course of a war hacking, I found out that one of my friend's computers did no input validation for a search script - I could put whole perl regular expressions in it as input. Is this an exploitable vulnerability? What can you run inside of m// to get information about someone else's s

Re: Please help!

2004-04-20 Thread Jason Dusek
Wiggins d Anconia wrote: Backticks, qx(), but then it is usually discouraged, why call a program written in the same language by shelling out? I think it's silly too, but I honestly don't know any better. So I looked up perlipc, and it's given me alot to think about but it hasn't exactly narrow

Please help!

2004-04-19 Thread Jason Dusek
I really need help with that system call thing! Here it is again: Hi List, I have code that looks like this: # #:# #:#:#:#:# #:#:#:#:#:# my $funk = '/home/jdd/sbin/idlwave2outline.pl'; my $jam = '/home/jdd/sbin/outline2html.pl -p -t'; my $web_dir = '/home/jdd/www'; Stuff Happens #:#:#:

Command Line Options In System()

2004-04-18 Thread Jason Dusek
Hi List, I have code that looks like this: # #:# #:#:#:#:# #:#:#:#:#:# my $funk = '/home/jdd/sbin/idlwave2outline.pl'; my $jam = '/home/jdd/sbin/outline2html.pl -p -t'; my $web_dir = '/home/jdd/www'; Stuff Happens #:#:#:#:#:# #:#:#:#:# #:# # # #:# #:#:#:#:# #:#:#:#:#:# su

Examples of Find

2004-04-17 Thread Jason Dusek
Hi Everyone, I'm back - in the intervening months I've lost a Macintosh and gained a work station running BSD and GNOME. I was wondering if anyone would post some good examples of use of File::Find - I would especially like to see how other people use the 'preprocess' option. I'm writing a sc

Re: The True Path to Learning Perl Re: [OT] Education Level

2003-12-09 Thread Jason Dusek
Hi Everyone, I would like to suggest that we drop the thread or bring it to focus on something less invidious than students vs. townies. I think it goes without saying that academia has many faults - but the autodidact is often a victim of his own whims and idiosyncracies. If this thread is t

Re: [OT] Education Level

2003-12-08 Thread Jason Dusek
Hi All, I think drieux has raised a good point in taking a shot at the 'learning how to think' snobbery too common among college graduates. It is a sad fact that college has very little to do with thinking or learning - rather it is all about: a) patience with idiots b) conformance to rules

Pointers and References

2003-11-30 Thread Jason Dusek
Hi Kids, What is a pointer and what is a reference? How are they different? If I read a book on C++ pointers and references, will it say the exact same things as a book on Perl references? - Jason When Banzan was walking through the Union Square greenmarket he overheard a conversation betwee

Re: Stupid Question

2003-11-28 Thread Jason Dusek
Hi Everyone, I guess drieux was write about perldoc -f 'delete' - it completely solved my problem. So as an act of penance to the Perl community, I will flagellate myself right here on this list! for (1..108) { print 'wap'; print 'ouch'; } That'll teach me to write to the list

Re: Stupid Question

2003-11-28 Thread Jason Dusek
Hi Everyone, On Friday, November 28, 2003, at 08:51 PM, drieux wrote: a. how did you initialize it to begin with and why not simple re-use that solution The hash consists of filenames, line numbers and strings. $HASH{$file}{$line} = line of code from some file. So the script goes along

Stupid Question

2003-11-28 Thread Jason Dusek
Hi Perl Beginners, Let's say I have a hash of hashes. And I want to use it over and over again, so I need to reinitialize it often. I suppose I could go through each key in the hash of hashes, and go through each key in the little hashes and use delete on each of them. But isn't there some

Re: Yahoo! Getter

2003-11-24 Thread Jason Dusek
On Monday, November 24, 2003, at 10:56 PM, Andrew Gaffney wrote: There is atleast 1 Perl program for downloading Yahoo mail out there. Okay, but let's say I want to learn how to do it anyway. It seems like a good practice problem. - Jason Wakuan complained when he saw a picture of 10 bulls: "

Yahoo! Getter

2003-11-24 Thread Jason Dusek
Hi All, Let's say I want to write a script that: 1) Signs on to Yahoo! Mail for me. 2) Hits the 'Forward' button for each of my messages. 3) Deletes everything and signs out. How do I learn to do this? Do I need any modules? Is this in the FAQ? What is t

Re: Don't Send To Me!

2003-11-24 Thread Jason Dusek
On Monday, November 24, 2003, at 02:21 AM, Randal L. Schwartz wrote: If you have procmail delivery, this rule works nicely: :0 Wh: msgid.lock | formail -D 8192 msgid.cache Right from procmailex(1). I am just going to use the 'Reply-To' header in Mail.app and see if it

Re: POD, Faq and tradition - Re: extracting email addys.

2003-11-24 Thread Jason Dusek
On Sunday, November 23, 2003, at 10:39 PM, R. Joseph Newton wrote: We newbies could just send the thing out to the list, and everyone could ignore it in good conscience. If the FAQ didn't help us, we could always repost with a note about "BadFAQ" in the subject line. That is actually what peldo

Don't Send To Me!

2003-11-23 Thread Jason Dusek
Hi There, Is there some way to get people on this list to stop sending me two emails at once? I am on the beginner's list - so when you send email to me and then cc to the list, I get two. Which is annoying. I suppose I could write some rules to kill duplicate messages, but I have got stuff

Re: POD, Faq and tradition - Re: extracting email addys.

2003-11-23 Thread Jason Dusek
Begin forwarded message: From: Jason Dusek <[EMAIL PROTECTED]> Date: Sat Nov 22, 2003 10:10:27 PM US/Central To: drieux <[EMAIL PROTECTED]> Subject: Re: POD, Faq and tradition - Re: extracting email addys. Hey People, On Saturday, Nov 22, 2003, at 16:18 US/Pacific, Randal L. Sch

Rephrasing the Question

2003-11-18 Thread Jason Dusek
Hi All, I need to write a script that finds the uniq() function in code for a data manipulation language, and replaces it with hyd_uniq(). Here are some examples: amend: u= uniq( timetags.bin_start, s ) to: u= hyd_uniq( timetags.bin_start, s ) amend: u_ens=fit_energy(uniq(fit_energy(*,i)

Word replacement

2003-11-18 Thread Jason Dusek
Hi There, How do I read a file and replace all occurences of a word in it with another word. For example, I want to read the file BUS_SCHEDULE and map bus to magic_bus. - Jason /• • If A equals success, then the formula is: • X+Y+Z = A • X is work. Y is play. An