FAQ

Search Discussions

410 discussions - 1,900 posts

  • I have a subroutine that returns 3 array refs. so i have: my ($stats, $totals, $loads) = gets_stats(); $stats and $totals are reference to arrays of arrays. $loads is just a ref to an array. what i ...
    Kipp, JamesKipp, James
    Jun 18, 2002 at 2:35 pm
    Jun 19, 2002 at 12:12 pm
  • Hi there, I think there's too many andvanced users here who ask DBI questions. I can't understand anything. Perl.beginners and perl.beginners.cgi are both too overloaded. Noone can read 80 massages a ...
    Yasen PetrovYasen Petrov
    Jun 29, 2002 at 7:16 am
    Jul 7, 2002 at 10:41 am
  • OK, here is a "real" beginners question, but interesting nonetheless: Sample code: $b = 1; $b = $b++; Result: $b = 1 Which strikes me as a little surprising. Shouldn't the result be 2? What is ...
    Michael TurnerMichael Turner
    Jun 30, 2002 at 2:25 pm
    Jul 1, 2002 at 5:54 am
  • Hi, all -- I'm trying to be good and so I use "my $variable" rather than making them global, and I prefer to not stick little [potentially-confusing] "my" declarations around through the code so I ...
    David T-GDavid T-G
    Jun 12, 2002 at 1:40 pm
    Jun 15, 2002 at 7:27 am
  • Hi all, I am runing a windows 2000 server and I have just installed perl that I got from ActiveState.com. I have been playing and have come up against a few problems. 1) It seems that writing perl ...
    A TaylorA Taylor
    Jun 18, 2002 at 1:34 pm
    Jun 18, 2002 at 9:16 pm
  • Hi, all -- [I should probably note early on that I do have some preferences that don't match what many coders do but which I will very probably continue anyway, like how I place braces, but that I ...
    David T-GDavid T-G
    Jun 8, 2002 at 11:48 pm
    Jun 10, 2002 at 4:09 am
  • 17

    split

    hi guys, I would like to split a line like that # FRI MAY 02 .... in two parts: $bash = # $rest = FRI MAY.... in my version ($bash, $rest) = split(/\s/, $line); $rest only contains "FRI" because the ...
    Stefan HabererStefan Haberer
    Jun 4, 2002 at 11:49 am
    Jun 28, 2002 at 5:26 pm
  • Hello, What is the best way to get just the date out of this string? $line ='June 29, 2002|6-7:45pm|Nashua Summer Fest|Downtown TBA|Nashua, NH'; my @date; @date = split(/\|/,$line); print $date[0]; # ...
    David GildenDavid Gilden
    Jun 17, 2002 at 6:41 am
    Jun 17, 2002 at 11:36 pm
  • Something occured to me the other day and I'm interested to know what people's opinions are on this list. When I'm reading the camel or other Perl books such as Perl and XML, the majority of the ...
    Nigel PeckNigel Peck
    Jun 21, 2002 at 3:43 pm
    Jun 27, 2002 at 12:55 pm
  • I have a perl scipt that emails certain information to me. I would like a certain line to be in bold or a different color when it is emailed. Is there a way to do this? Ernest P. Tucker II Network ...
    Tucker, ErnieTucker, Ernie
    Jun 26, 2002 at 5:37 pm
    Jun 26, 2002 at 7:22 pm
  • Hello, I'm a sys-admin on an AIX (4.3) machine, and I'm trying to work with a vendor program that doesn't behave very nicely. Basically, if a user's connection to the server is inappropriately ...
    Akens, AnthonyAkens, Anthony
    Jun 11, 2002 at 3:51 pm
    Jun 13, 2002 at 5:16 pm
  • 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 ...
    Bob ackermanBob ackerman
    Jun 10, 2002 at 5:36 pm
    Jun 12, 2002 at 1:38 pm
  • Sometimes I'd like to run a perl program in a similar way as one can run a shell script with the -x switch. Where all commands and actions are printed to tty as the occur. How does one simulate that ...
    Harry PutnamHarry Putnam
    Jun 22, 2002 at 4:34 am
    Jun 24, 2002 at 11:55 am
  • Hi, I have a requirement. I need to output data in a file which will be column specific. Eg. Column 1-2 Data1 Column 3-10 Data2 Column 11-12 Data3 ....and so on. Now, the data can be both decimal as ...
    Shishir K. SinghShishir K. Singh
    Jun 17, 2002 at 2:24 pm
    Jun 21, 2002 at 8:14 pm
  • Slightly OT, but does anyone know how to pass an empty string to a script via the command line? I have a script that is invoked via: rename match-str replace-str <list of files .... where the rename ...
    Bryan R HarrisBryan R Harris
    Jun 10, 2002 at 10:38 pm
    Jun 11, 2002 at 4:23 pm
  • Hey all, Okay.. I am stumped. I must be doing something wrong. I am going to post only the relevant code, let me know if you need more. # $FUNC is a ref to a hash ## in a subroutine foreach my ...
    Nikola JanceskiNikola Janceski
    Jun 6, 2002 at 3:33 pm
    Jun 7, 2002 at 12:45 am
  • hi all of you, i have a multiple perl files that use the same subroutines, the only way i know to handle this - i know its not so cleaver - is to copy & paste the portion of the subroutine in all ...
    Hytham ShehabHytham Shehab
    Jun 23, 2002 at 9:31 pm
    Jun 26, 2002 at 4:58 pm
  • I need a regex to match a string if the first colon in the string is immediately followed by another colon. For example: blah::blah blah: This would match blah:blah blah: This would not ...
    Akens, AnthonyAkens, Anthony
    Jun 19, 2002 at 6:22 pm
    Jun 21, 2002 at 7:33 am
  • Just wondering if anyone here has experience with code that allows Getopt::Std to handle more arguments per option than the normal 1? I've had occasion to want to process several for each option at ...
    Harry PutnamHarry Putnam
    Jun 19, 2002 at 11:13 pm
    Jun 20, 2002 at 6:01 pm
  • How would I get rid of one trailing white space character in $HASH{$key} and reassign the result OR how would I match a variable with 1 trailing white space to a variable that has no trailing white ...
    Alaric Joseph HammellAlaric Joseph Hammell
    Jun 11, 2002 at 8:28 pm
    Jun 17, 2002 at 7:19 pm
  • I have this situation: $in = "02 Jul 5.00 (YHZ GA-E)" I want: $out = "YHZGA-E" How do I extract the information between the ()s ? Other than the parens all other characters are likely to change. -todd
    Todd shifflettTodd shifflett
    Jun 26, 2002 at 3:31 pm
    Jun 26, 2002 at 8:43 pm
  • Hi, Let's say I'm opening a file. How do I read the last line of the file? is there any function in doing so? Thanks.
    Karen Liew Ying PingKaren Liew Ying Ping
    Jun 24, 2002 at 10:10 am
    Jun 25, 2002 at 5:02 am
  • Hi, I have recuperated a module from the web and I interfaced with it but STDOUT is closed . If I do a : print STDOUT "hello\n" in my script, nothing appeared . I don't know where STDOUT is closed ...
    Franck FASANOFranck FASANO
    Jun 13, 2002 at 2:19 pm
    Jun 15, 2002 at 7:04 pm
  • Hello, I have a requirement to get the IP address of a user logged from a remote machine on to UNIX machine. Now the user can be using multiple logins through VPN or otherwise. I need to create ...
    Shishir K. SinghShishir K. Singh
    Jun 7, 2002 at 4:42 pm
    Jun 7, 2002 at 9:43 pm
  • [..] [..] the code that you wrote fully executed - the problem is that it did exactly what you told it - not what you wanted.... 8-) I think the confusion here is understanding that use FOO; will ...
    DrieuxDrieux
    Jun 24, 2002 at 8:04 pm
    Jun 28, 2002 at 6:30 pm
  • Hi there, I want to write a perl application for a win32 operating system. The application must be using windows,forms, the same interfaces like the ones you get using delphi or visual basic. I mean ...
    Joe EchavarriaJoe Echavarria
    Jun 27, 2002 at 3:01 pm
    Jun 27, 2002 at 9:31 pm
  • Is there? So that I don't have to constantly type it. Thanks.
    LRZLRZ
    Jun 24, 2002 at 4:22 pm
    Jun 26, 2002 at 9:40 pm
  • how does one prevent this script from printing "hello"?. in large scripts where you may inadvertently reuse variable names, this causes errors. is there some way to get perl to disallow the global ...
    Martin A. HansenMartin A. Hansen
    Jun 20, 2002 at 7:20 am
    Jun 20, 2002 at 6:13 pm
  • Hello, I have an smp machine that I want to run two instances of setiathome on. I have two s@h directories (/root/.setiathome and /root/.setiathome2). I wrote this to run both of them at the same ...
    Tyler LongrenTyler Longren
    Jun 18, 2002 at 4:10 pm
    Jun 20, 2002 at 2:32 pm
  • Hi all I posted this on the CGI list but no response at all. Please have a look at this problem. I am reading from an html file and writing to another. The while loop terminates before the complete ...
    Aman cgiperlAman cgiperl
    Jun 10, 2002 at 5:22 pm
    Jun 10, 2002 at 7:15 pm
  • Hello. I am writing a quick script in order to parse a users $PATH variable, but I hit upon a quandry. The PATH environment is one long string with element separated by a ":", no mystery there, but ...
    James KeltyJames Kelty
    Jun 4, 2002 at 9:57 pm
    Jun 5, 2002 at 3:13 pm
  • Hi, I need some help on the following. In my script I show users some infodocs after they are verified to be valid users. Users can have the permissions following the ruleset: - user (all perm) - ...
    David vd Geer Inhuur tbv IPlibDavid vd Geer Inhuur tbv IPlib
    Jun 24, 2002 at 10:07 am
    Jun 25, 2002 at 1:19 pm
  • Hi, I have a C program. In there is a function that I need for perl. This is the first time I am dealing with the C / Perl Interface. Is there any detailed reading material on how it's done ?? Any ...
    Shishir K. SinghShishir K. Singh
    Jun 18, 2002 at 2:00 pm
    Jun 19, 2002 at 8:07 pm
  • Hi, Is there a way to get the number of lines in a file. Conditions: a) Without using backticks on wc -l b) Without opening the file and looping over the records Thanks Shishir
    Shishir K. SinghShishir K. Singh
    Jun 18, 2002 at 3:49 pm
    Jun 19, 2002 at 7:30 pm
  • Can this be simplified with less variables? sub rcsname { my $file = shift; (my $rcsfile = $file) =~ s{somepattern}{andsubstitution}; return $rcsfile; } ### remember that the original arguement ...
    Nikola JanceskiNikola Janceski
    Jun 11, 2002 at 1:16 pm
    Jun 12, 2002 at 8:12 pm
  • Hello folks, I am trying not to re-invent the wheels. So I was wondering whether there is a little program that you good people might know of the would do the following for me: Here's an example: ...
    Rasoul HajikhaniRasoul Hajikhani
    Jun 7, 2002 at 7:50 pm
    Jun 8, 2002 at 10:16 pm
  • Hello, I am facing a problem in using regular expression on array. My code is written below: open(FILE, $dirvalue) ; my @lines = <FILE ; print @lines; # prints the file contents if( @lines =~ ...
    Ankit GuptaAnkit Gupta
    Jun 5, 2002 at 7:50 pm
    Jun 7, 2002 at 4:29 pm
  • Hi guys, I will have the file that will start with the following line: Dear Name (ID12345) .... .... .... .... Do you know how can I parse the above file, so I can retrieve the ID12345? idNumber = ...
    LzLz
    Jun 6, 2002 at 8:15 pm
    Jun 6, 2002 at 10:40 pm
  • Can someone help please. I'm learning from scratch. What is this? $_='My email address is <webslave@work.com .'; /(<.* )/i; print "Found it ! $1\n"; I can only identify one command here. Print. How ...
    Adam VardyAdam Vardy
    Jun 5, 2002 at 2:25 am
    Jun 6, 2002 at 12:55 pm
  • Is there any function to tell if a number is even or odd? I am looking for an easy way to loop through a list and output table cell bgcolor based on even / odd. if its an even numbered row make it ...
    Zachary BuckholzZachary Buckholz
    Jun 5, 2002 at 2:09 am
    Jun 5, 2002 at 6:20 pm
  • Hello all, I am working on a script that I have several debug statements that try to tell me what is contained in a hash referrence. While I am tailing the log file, the hashes derefference ...
    ShawnShawn
    Jun 22, 2002 at 9:02 pm
    Jun 23, 2002 at 12:50 pm
  • Lo all, How can I convert a date such as '18 Jun, 2002 at 11:00:00 (SAT)' into a DD/MM/YYYY HH:MM string? I've been on google for quite some time now, and looked at quite a few CPAN stuff, but I ...
    Chris KnipeChris Knipe
    Jun 19, 2002 at 2:33 am
    Jun 20, 2002 at 12:17 pm
  • Greetings! I'm in need of passing parameters via command line to a program. I understand the basics of Getopt::Std and Getopt::Long. However, there is something I'd like to do which I don't think ...
    Jason FrisvoldJason Frisvold
    Jun 19, 2002 at 3:22 pm
    Jun 19, 2002 at 5:08 pm
  • Hi, I just added to my Linux System(RedHat), MySQL and i want to write a program in PERL that adds user account. if i'm working directly with Linux i would open the shell command and type shell mysql ...
    AnthonyAnthony
    Jun 16, 2002 at 7:50 pm
    Jun 17, 2002 at 5:06 am
  • , I seem to recall a discussion on a RegEx to match an IP address, but can't seem to find it. Anyone have any ideas, or recall what it would be? Or could toss it together? First Octet is 1-255 ...
    Tim MussonTim Musson
    Jun 14, 2002 at 12:47 pm
    Jun 14, 2002 at 8:29 pm
  • Hi folks! Well, here's one I'm just not getting to grips with. I'm parsing a configuration file for an application, and it has a parameter as such: Parameter=Value1 Value2 Value3 \ Value4 Value5 ...
    Anders HolmAnders Holm
    Jun 11, 2002 at 1:40 pm
    Jun 12, 2002 at 1:53 pm
  • Hi, How can fetch all the environment variables and print them to the screen? +-----------------------------------------------------------------------------------+ Philip Humeniuk phumes1@rogers.com ...
    Phumes1Phumes1
    Jun 11, 2002 at 6:49 pm
    Jun 11, 2002 at 7:27 pm
  • Might I trouble you kind folks for a bit of feedback? This is my first real script I put together in which it collects all users from the output of the 'repquota -a' command who have not yet had ...
    William MelansonWilliam Melanson
    Jun 10, 2002 at 12:37 pm
    Jun 10, 2002 at 9:52 pm
  • We have a log file that gets really huge, so I wanted to to edit it in place to delete old entries and only leave today's entries in the current log. The process writing to the log doesn't come down ...
    Rice, Elizabeth A.Rice, Elizabeth A.
    Jun 28, 2002 at 6:28 pm
    Jul 1, 2002 at 5:39 pm
  • Hello, I am currently working on a search-eingine for .txt files I am searching for $word in each .txt file. Now of course the ability to search for 2 words in the document, must become possible. ...
    David vd Geer Inhuur tbv IPlibDavid vd Geer Inhuur tbv IPlib
    Jun 25, 2002 at 1:56 pm
    Jun 28, 2002 at 7:58 pm
Group Navigation
period‹ prev | Jun 2002 | next ›
Group Overview
groupbeginners @
categoriesperl
discussions410
posts1,900
users273
websiteperl.org

273 users for June 2002

Drieux: 200 posts David T-G: 91 posts Shishir K. Singh: 72 posts Felix Geerinckx: 69 posts John W. Krahn: 63 posts Jeff 'japhy' Pinyan: 60 posts Bob Showalter: 58 posts Nikola Janceski: 53 posts Janek Schleicher: 51 posts Jenda Krynicky: 47 posts Timothy Johnson: 47 posts Peter Scott: 36 posts David vd Geer Inhuur tbv IPlib: 32 posts Kipp, James: 31 posts Shawn: 27 posts Sudarsan Raghavan: 27 posts Bob ackerman: 22 posts Todd Wade: 22 posts Bryan R Harris: 21 posts Nigel Peck: 21 posts
show more
Archives