FAQ

Search Discussions

458 discussions - 1,975 posts

  • anyone know of a way to determine the user who last accessed or modified a file ? thanks
    Kipp, JamesKipp, James
    Jul 1, 2002 at 4:43 pm
    Jul 2, 2002 at 3:21 pm
  • Funny. This simple test works for me: <snip use strict; use warnings; my $t = &fun; print @$t[0]; # prints a sub fun { my @arr = qw(a b c d e); return \@arr; } </snip hth Toby -----Original ...
    Toby StuartToby Stuart
    Jul 10, 2002 at 6:57 am
    Jul 11, 2002 at 3:43 am
  • Inside a package, there are some subs. package myPackage; BEGIN{} sub doA { ..... } sub doB { ..... } sub doC {.....} sub doZ { ..... ; my $something = doA(); $something = doB($something); $something ...
    Connie ChanConnie Chan
    Jul 19, 2002 at 4:25 pm
    Jul 23, 2002 at 4:04 pm
  • Hi I'm trying to get my script to recognize the date and time. I thought I had it but I keep getting errors all over. Please take a look and tell me whats wrong Thanks # Here we define the variables ...
    JffusionJffusion
    Jul 9, 2002 at 10:09 pm
    Jul 15, 2002 at 4:07 pm
  • Hello all, My hash keys look something like this: So I am thinking a cmp, as opposed to <= is best. What I want is for the keys to be sorted as follows: .. .. .. This is what I have in my script at ...
    NkuipersNkuipers
    Jul 24, 2002 at 5:39 pm
    Jul 25, 2002 at 7:24 pm
  • Hi, Im looking for a method to exact the biggest element (number) out of array. Does anyone know a function for that? cu Konrad
    Konrad FoerstnerKonrad Foerstner
    Jul 16, 2002 at 4:34 pm
    Jul 19, 2002 at 8:09 pm
  • Is there any speed difference in this? my @crap = map { map{ s/\.\w+$//; $_ } (glob($_)) } qw(*.pl *.pgp); and my @crap = map{ s/\.\w+$//; $_ } map { glob($_) } qw(*.pl *.pgp); Nikola Janceski ...
    Nikola JanceskiNikola Janceski
    Jul 15, 2002 at 7:06 pm
    Jul 15, 2002 at 9:14 pm
  • This is a list for beginners, right? So perhaps no one will be too annoyed if I ask what is probably a really stupid question . . . I have a text file with occasional strings enclosed in braces: ...
    David CarpenterDavid Carpenter
    Jul 8, 2002 at 2:45 am
    Jul 9, 2002 at 5:16 am
  • Hi All, I have an array of directory files and I want to search via the date the directory was created. Is there a function or dash option that handles this? Thanks, William Black Duke Energy 401 S. ...
    William J BlackWilliam J Black
    Jul 1, 2002 at 3:54 pm
    Jul 6, 2002 at 11:24 am
  • Hi, I am new to Perl just over a month now. I have tried other programming languages and they just seem to hard to understand. I have found Perl to be a lot easier to understand, and that brings me ...
    Scott BarnettScott Barnett
    Jul 31, 2002 at 1:45 pm
    Aug 21, 2002 at 11:31 am
  • Is there a quicker way to substitute an item in a line than reading the line in each time? I am writing a script to convert RTF to XML. One part of the script involves simple substitution, like this: ...
    Paul TremblayPaul Tremblay
    Jul 26, 2002 at 5:56 pm
    Jul 30, 2002 at 3:18 am
  • I just finished my first version of a script that converts rtf to xml and was wondering if I went about writing it the wrong way. My method was to read in one line at a time and split the lines into ...
    Paul TremblayPaul Tremblay
    Jul 14, 2002 at 2:35 am
    Jul 15, 2002 at 8:30 pm
  • Does there any reference to study those syntax (grammar) about Perl ? just like - {} [] // || ? ..... etc. They are quite vary types of usage on different situation, and just quite confuse about ...
    Connie ChanConnie Chan
    Jul 26, 2002 at 2:59 pm
    Aug 1, 2002 at 10:56 am
  • I have a few suggestions. 1. Practice. 2. Practice. 3. Find useful things to do with Perl, and you'll learn alot faster than coming up with arbitrary scripts. 4. Take a break before you pull that ...
    Timothy JohnsonTimothy Johnson
    Jul 16, 2002 at 3:48 pm
    Jul 17, 2002 at 8:30 pm
  • I have a large perl package and need just one small standalone subroutine in it. The use statement will lead to compile errors if I do not have all the dependencies in my perl install. A work around ...
    ChrisChris
    Jul 14, 2002 at 12:31 pm
    Jul 15, 2002 at 1:11 pm
  • Hi filename Rnott230602.txt I want to break down the name and compare with other text, it breaks down as R / nott / 230602 (3 items) the length does not change. Now I know I can split() each char and ...
    Steven_masseySteven_massey
    Jul 2, 2002 at 7:24 am
    Jul 8, 2002 at 10:48 am
  • When I try to install libwww-perl through ppm3 from the ActiveState repository I get Error: PPD for 'R:/inetpub/wwwroot/www2.activestate.com/PPMPackages/5.6-plus/libwww-perl.ppd' could not be found. ...
    Nigel PeckNigel Peck
    Jul 3, 2002 at 9:56 am
    Feb 17, 2003 at 2:00 pm
  • Would anyone tell me how to do something like this ? sub something { my (%hash, %hash2, @array) = @_; [......] return (%result) } my %restult = something ( %hash, %hash2, @array);
    Connie ChanConnie Chan
    Jul 26, 2002 at 3:05 pm
    Jul 27, 2002 at 2:01 am
  • Hi, I couldn't seem to find a built-in function for finding the index of an element in an array...so I wrote this one: -------------------------------------------------------------------- # ...
    Daniel DavidDaniel David
    Jul 25, 2002 at 10:01 am
    Jul 25, 2002 at 8:54 pm
  • Hi I would like to know how to compare 2 arrays. I have 2 arrays and I would like to compare the contents of the data. It doesn't matter in which order the data is stored so long as its the same. So ...
    Merritt KrakowitzerMerritt Krakowitzer
    Jul 23, 2002 at 7:40 am
    Jul 24, 2002 at 12:27 pm
  • I was just wondering if there is anything similar in perl for unix commands pushd / popd ?? Thanks Shishir
    Shishir K. SinghShishir K. Singh
    Jul 23, 2002 at 6:15 pm
    Jul 23, 2002 at 7:53 pm
  • Heyho! My case: I'm writing a program which analyses some input to get some percent values. These values should be drawn in a diagramm (is use GD for that). To use the area of the created picture ...
    Konrad FoerstnerKonrad Foerstner
    Jul 18, 2002 at 10:14 am
    Jul 19, 2002 at 8:51 am
  • Hello all, I am writing a script for a client and they have requested an easy way to configure their script.....without having to enter the script code itself. I'm not to crazy about using a config ...
    Kevin OldKevin Old
    Jul 16, 2002 at 3:49 pm
    Jul 17, 2002 at 9:17 pm
  • Hello all, I'm trying to get this line to work (!$opt_Z) ? die "Must supply Market\n" : $mkt = $opt_Z; and I keep getting compiler errors. Basically I'm trying to consolidate: if (!$opt_Z) { die ...
    Kevin OldKevin Old
    Jul 16, 2002 at 8:55 pm
    Jul 17, 2002 at 4:09 am
  • Lo all, Very stupid it must be, but I can't see what I'm doing wrong here... The following if statement, always returns true (prints "a"), regardless of what the value of $SiteType is... ...
    Chris KnipeChris Knipe
    Jul 10, 2002 at 8:09 pm
    Jul 11, 2002 at 4:08 pm
  • In Excel, there is an interesting function which can sort a table by fields with any order and hierarchy order. Is there any module can do this for whatever array of array, hash of array... etc. ? ...
    Connie ChanConnie Chan
    Jul 30, 2002 at 7:27 am
    Jul 31, 2002 at 5:31 pm
  • Hi, I have instances where I want to delete duplicate elements out of an array. Is there an easy way to do this? -Sarah
    Kirby_SarahKirby_Sarah
    Jul 30, 2002 at 7:05 pm
    Jul 30, 2002 at 7:21 pm
  • Hi All Scuse my ignorance (and illiteracy) but what is munging? It seems to crop-up occasionally and I have absolutely no clue... Cheers James ...
    James CampbellJames Campbell
    Jul 29, 2002 at 3:57 pm
    Jul 29, 2002 at 8:45 pm
  • I have a simple perl script which I can run from the command line in the form: perl test.pl I am trying to run this from Cron every 5 minutes, but being as unfamilair with Cron as with Perl, I having ...
    Max HugenMax Hugen
    Jul 26, 2002 at 4:43 am
    Jul 27, 2002 at 3:54 am
  • I want to delete files. I am not able to delete , what is the wrong thing I am doing here. I am able to see the file in @privates I am getting following output: 0 deleted Attempting to delete ...
    Javeed SARJaveed SAR
    Jul 25, 2002 at 6:48 am
    Jul 25, 2002 at 7:21 pm
  • Consider a file containing this pattern: p1 p2 I can match for p1 and p2 like this: $/ = ''; while(<MYFILE ) { if (m/(p1)*.(p2)/ms) { print "match! I found $1 and $2\n."; } } However, the match fails ...
    David NewmanDavid Newman
    Jul 22, 2002 at 10:27 pm
    Jul 23, 2002 at 12:37 pm
  • I'm use flat files to manage a list containing approx 25,000 records. For updates, I write to a temp file then unlink main and rename temp file to main. I use flock for both temp and main files ...
    JeffJeff
    Jul 18, 2002 at 12:02 am
    Jul 19, 2002 at 3:56 pm
  • Some days ago, I've interested in the using of 'our' var, however, I do have some problem on using this with require. ### Lib 1 ### use strict; our %abc; $abc{a} = 1; $abc{b} = 2; ### EOF Lib 1 ### ...
    Connie ChanConnie Chan
    Jul 15, 2002 at 1:28 pm
    Jul 15, 2002 at 3:03 pm
  • Hi all, With get method from form, we always see that the $ENV{QUERY_STRING} like this : &message=%20%2F%15+...&....... btw, what is the name of that string in types of ? Escape ? Unicode ? With ...
    Connie ChanConnie Chan
    Jul 10, 2002 at 10:23 pm
    Jul 11, 2002 at 6:23 pm
  • I'm facing what I believe to one of the classic text manipulation problems, transforming a document which was typed with a hard return at the end of every physical line, and two consecutive newlines ...
    KEVIN ZEMBOWERKEVIN ZEMBOWER
    Jul 29, 2002 at 3:21 pm
    Jul 31, 2002 at 3:31 am
  • Is there a way to feed a switch to a PerlApp generated .exe? I have a perl script that takes some command line arguments: For instance "perl -s myscript.pl -g -f" But when I generate a myscript.exe ...
    Robert SmithRobert Smith
    Jul 29, 2002 at 5:28 pm
    Jul 30, 2002 at 4:22 pm
  • Hello everyone, I sure hope I am posting in the right place, the "beginners" definitely applies here. I have a web hosting account and my ISP has the following Perl modules installed: AnyDBM_File,pm ...
    GarryGarry
    Jul 23, 2002 at 8:00 pm
    Jul 24, 2002 at 2:51 pm
  • Hi all, If someone does't have a certain perl module, where might one get it from? William Black MSN Photos is the easiest way to share and print your photos: ...
    William BlackWilliam Black
    Jul 8, 2002 at 5:39 pm
    Jul 16, 2002 at 2:21 pm
  • Hello All, Just a quick question on deleting files in Perl. I am trying to delete some files in a directory, but I do not know their names...just ending extension... I have tried: One way: unlink ...
    Michael PastoreMichael Pastore
    Jul 15, 2002 at 12:49 pm
    Jul 15, 2002 at 2:15 pm
  • There seems to be something fishy with your system or the files you are using. On Win32, the line terminator is usually "\015\012", or CRLF. Of course, the file you are reading may not have the usual ...
    Paul JohnsonPaul Johnson
    Jul 14, 2002 at 12:37 am
    Jul 14, 2002 at 9:47 am
  • Hi All, I am new to Perl and need help to solve this one ! I have a txt file and the contents of the file are as below : ---------------CONTENTS OF TEXT FILE-------------------------- Abdullah Ahmed ...
    Sunish KapoorSunish Kapoor
    Jul 3, 2002 at 10:47 am
    Jul 4, 2002 at 9:34 am
  • $\ = "\n"; $date = "20020731"; print join "/", ($date =~ /(\d{4})(\d{2})(\d{2})/)[1,2,0]; # this works print join "/", ($date =~ /(\d{4})(\d{2}){2}/)[1,2,0]; # this doesn't __END__ why did the second ...
    Nikola JanceskiNikola Janceski
    Jul 31, 2002 at 3:28 pm
    Jul 31, 2002 at 8:07 pm
  • Hi, How can I replace the literal "nlf" with a variable in the code below? Thanks in advance. sub parseLogLine { $line = $_; %searchInfo = (); @searchInfo = split / +/, $line; # found any listings? ...
    Larry SteinbergLarry Steinberg
    Jul 30, 2002 at 3:06 pm
    Jul 31, 2002 at 4:13 pm
  • Hello, I wrote a big skript which uses net::ping (ping.pm) (and tk). I noticed that the resultes of Net::Ping are not identical to the system commad ping. Much more Items are not reachable over ...
    AngersteinAngerstein
    Jul 30, 2002 at 8:13 am
    Jul 31, 2002 at 9:12 am
  • Can I put an assignment in an if(){} condition? ex: if( my($var) = $string =~ /(\d+)/){ # do stuff here } And does the scope of $var in the example scope to the closing if } or )? And are rubber ...
    Nikola JanceskiNikola Janceski
    Jul 26, 2002 at 2:45 pm
    Jul 27, 2002 at 5:02 pm
  • [ please cc: me as I am on digest and I may miss a reply] I have the following snippet of code: if($line=~/Connect\s/) { print $line; if($1=~/[0-9]/) { print "$1\n"; } } The first if is OK, I get ...
    SteveSteve
    Jul 26, 2002 at 11:24 pm
    Jul 27, 2002 at 6:14 am
  • Hi having a little trouble installing the Net::SMTP module what pre-requisite modules do i need to install first? think i need : Crypt::DES Digest::HMAC Digest::MD5 and Digest::SHA1 but again having ...
    Stephen ReddingStephen Redding
    Jul 19, 2002 at 9:09 am
    Jul 24, 2002 at 5:01 am
  • I figure that I can use substr() to cut up a string, but how do I make it between words? How do I measure a string to see if it is greater than 85 characters? Basically, if the string is more than 85 ...
    David GerlerDavid Gerler
    Jul 23, 2002 at 6:18 pm
    Jul 23, 2002 at 7:29 pm
  • Hi, I have a strange error in my script. It should paint a column of lines next to each other in colors which are determinated by a given sequence of letters. It works...but only to the position of ...
    Konrad FoerstnerKonrad Foerstner
    Jul 22, 2002 at 6:14 pm
    Jul 23, 2002 at 7:31 am
  • Ok, I need to ask you guys for some help and advice. I am working on learning Perl, but am having a hard time. I am very familiar with C++, but Perl seems a lot more complex for some reason. I ...
    David FisherDavid Fisher
    Jul 18, 2002 at 6:35 pm
    Jul 22, 2002 at 4:51 pm
Group Navigation
period‹ prev | Jul 2002 | next ›
Group Overview
groupbeginners @
categoriesperl
discussions458
posts1,975
users330
websiteperl.org

330 users for July 2002

Connie Chan: 130 posts Drieux: 116 posts John W. Krahn: 89 posts Jeff 'japhy' Pinyan: 79 posts Nikola Janceski: 72 posts Timothy Johnson: 66 posts Felix Geerinckx: 62 posts Janek Schleicher: 58 posts Jenda Krynicky: 51 posts Bob Showalter: 45 posts Peter Scott: 38 posts Chris: 28 posts Nkuipers: 28 posts David T-G: 27 posts Shishir K. Singh: 27 posts Nigel Peck: 25 posts Wiggins d'Anconia: 25 posts Sudarshan Raghavan: 24 posts George Schlossnagle: 23 posts Tanton Gibbs: 23 posts
show more
Archives