Search Discussions

162 discussions - 889 posts

  • I'm working on a new perl script thats giving me fits. Ive never quite seen anything like this. here is the command that is not giving me the results I want. @domain = split(' ',$domainlist); what ...
    Rance HallRance Hall
    Apr 26, 2006 at 8:19 pm
    May 3, 2006 at 9:20 am
  • Hi, I have printed one statement in perl . now i want to print another statement on second line . i just wanted to know that what is the syntax in perl to go to the next line ? Plz let me know. ...
    Irfan J SayedIrfan J Sayed
    Apr 5, 2006 at 4:47 pm
    Apr 26, 2006 at 4:22 am
  • 27


    This is kind of a frivolous question, but . . . is there some way to golf this? while (< ) { s/\n/ /; print; } -- Chad Perrin [ CCD CopyWrite | http://ccd.apotheon.org ] "There comes a time in the ...
    Chad PerrinChad Perrin
    Apr 20, 2006 at 1:37 am
    Apr 25, 2006 at 11:50 am
  • I need to discard the first 9 lines of input before I get to the data I'm interested in... I'm using: for (1..9) { < ; } ... but that feels a little wordy. Is there a more terse way to do it? (I love ...
    Bryan R HarrisBryan R Harris
    Apr 10, 2006 at 6:14 pm
    Apr 14, 2006 at 10:09 pm
  • This code works, but I don't understand it. It is in a source file with the extension of ".pm". I have a static variable agent that needs to be initialized prior to the first function call. Should ...
    Apr 19, 2006 at 8:06 pm
    Aug 9, 2006 at 11:38 pm
  • Hi , print $line if ($line =~ /pattern1 && pattern2 && pattern3/); works .. but my $regex="$pattern1 && $pattern2 && $pattern3"; print $line if ($line =~ /$regex/); doesn't work... Any clues ? Thanks,
    Sonika SachdevaSonika Sachdeva
    Apr 11, 2006 at 10:39 pm
    Apr 12, 2006 at 3:44 pm
  • Hi Anyone know of a way to create a loop (or something similar) that automatically schedules the execution of a sub-routine periodically from within a program, for example execute check() every 600 ...
    James TurnbullJames Turnbull
    Apr 4, 2006 at 2:36 am
    Apr 4, 2006 at 12:58 pm
  • Hello I am wondering how the chomp function works. I am looking to see how I can truncate new line and/or carriage returns from a string. Will chomp do nothing if there are no carriage return or line ...
    Apr 27, 2006 at 5:51 am
    Apr 28, 2006 at 5:40 pm
  • I would like to accept monetary values like $234.00 $2678 but not values with letters like $333.oo This script below almost works, but I can't get it to catch the $40o.89 Is there a simpler way to do ...
    Apr 6, 2006 at 12:29 pm
    Apr 19, 2006 at 2:48 pm
  • If I want to use regular expression to extract the charactors after the last '/' in the url, but below regexpr doesn't work, what I do wrong? $url = 'http://website.com/path/file_name.img'; if ...
    Ken PerlKen Perl
    Apr 26, 2006 at 2:20 am
    Apr 27, 2006 at 12:26 am
  • Hello, When I receive a signal (for example,TERM or INT) from terminal,I want to get the process exit immediately.But the process have some childs running,so he would tell the childs to exit before ...
    Practical PerlPractical Perl
    Apr 9, 2006 at 4:52 am
    Apr 11, 2006 at 8:40 am
  • Hi Guyz, i am writin a script to automate the command snmpwalk by reading the contents of a file. Below is the snippet $file_name="somefile.txt"; open(FILE,"< $file_name"); while(<FILE ) { my $ip; my ...
    Apr 5, 2006 at 6:46 am
    Apr 26, 2006 at 6:54 am
  • Howdy list, I'm trying to see if I can do this in one regex instead of multiple stage, mainly for educational purposes since I already have it in multipel steps. I am trygin to get each string ...
    Apr 14, 2006 at 12:16 am
    Apr 19, 2006 at 12:24 am
  • Hi All, I need to run the windows copy command from command prompt to copy several folders and files in specific folder to another folder I am running following command C:\Documents and ...
    Irfan J SayedIrfan J Sayed
    Apr 6, 2006 at 2:52 pm
    Apr 7, 2006 at 9:11 pm
  • That is, why does the output differ between: perl -e "print join(\"\n\",@{[`dir`]});" and dir | perl -pne ""
    Michael GoldshteynMichael Goldshteyn
    Apr 6, 2006 at 3:55 pm
    Apr 6, 2006 at 11:37 pm
  • I am just starting out teaching myself Perl from books and web resources so I apologise if my questions seems a little straight forward but I was hoping to ask here to get clarification and so I hope ...
    M K ScottM K Scott
    Apr 18, 2006 at 12:37 pm
    May 29, 2006 at 4:16 am
  • i'm try to use 'Tie::StdScalar' but perl tells me it can't find it. I've pushed '/usr/share/perl/5.8.7' onto @INC. the error is: Can't locate Tie/StdScalar.pm in @INC in ...
    Tom arnallTom arnall
    Apr 29, 2006 at 5:22 pm
    May 4, 2006 at 9:19 am
  • Hi All, I'm working through the exercises in the Alpaca book. I don't understand why you have to pass the check_items_for_all subroutine a reference to a hash. Why can't you just pass it the hash ...
    Brian VolkBrian Volk
    Apr 14, 2006 at 4:15 pm
    Apr 16, 2006 at 11:16 am
  • I'm trying to use the Class::Struct to create some C-Like structs but I'm unable to dereference any array elements in the struct. I'm admittedly a Perl newbie trying to map my C programming ...
    Apr 10, 2006 at 6:57 pm
    Apr 11, 2006 at 11:30 pm
  • I have a perl script that becomes a zombie. It runs fine for days or weeks checking for new data every 60 seconds. But after a long period of time running on Red Hat 9, Fedora Core 4, and now Fedora ...
    John AckleyJohn Ackley
    Apr 6, 2006 at 11:55 am
    Apr 7, 2006 at 10:39 am
  • With the intention of optimization, I am looking for a way around using *eval* in the below snippet at line 19: my $value = eval $key; The objective is to get from $key to $value, knowing that $key ...
    Ryan GiesRyan Gies
    Apr 6, 2006 at 8:11 pm
    Apr 7, 2006 at 4:23 am
  • Looks like I picked the wrong day to stop sniffing glue. I meant \s, of course. In this case the problem is not with the wording of the doc, but with the confusing array of options. My same ...
    Timothy JohnsonTimothy Johnson
    Apr 26, 2006 at 9:49 pm
    Apr 28, 2006 at 11:11 am
  • In perldoc under this topic s is listed as "Treat string as a single line" and m as Treat string as multiples lines". If I have text that has varying spaces at the begging of each line, and I use ...
    Bowen, BruceBowen, Bruce
    Apr 21, 2006 at 2:11 pm
    Apr 27, 2006 at 1:23 pm
  • Hi Folks, I need to develop a script where in i need to first check the type of OS and then go about in finding the drives. I need your help in getting an idea of how to start about this... Thanks in ...
    Apr 25, 2006 at 12:02 pm
    Apr 26, 2006 at 4:18 am
  • Hi all, Thank you all for reply my post in advance. I install in new module like this: c:/perl/local/new.pm. How should tell the perl to look at it in addition to the default paths? Li
    Chen liChen li
    Apr 14, 2006 at 9:40 pm
    Apr 15, 2006 at 6:39 pm
  • Hi, each file name begins with xtst of which I've near 18 of these small files (for example, xtst033006, xtst040106, xtst022406 etc. etc.) these text files may contain code snippet and/or help, howto ...
    Apr 7, 2006 at 9:50 am
    Apr 12, 2006 at 5:45 am
  • Hi Folks, i have written down a code in perl which is used as a file analyser. I need to run the same on Windows 2000. Should i need to install Active State Perl on the same. Is there any other ...
    Apr 24, 2006 at 5:09 am
    Apr 25, 2006 at 5:30 am
  • I'm trying to scrape the data behind the form at http://www.theblackchurch.com/modules.php?name=Locator As a true beginner with Perl (I know some php), I'm working from training scripts that scrape ...
    Apr 10, 2006 at 10:30 pm
    Apr 13, 2006 at 3:15 am
  • Hello, I am trying to come up with a function, or formula calculation, to determine the total days of a given month, IE: April which has 30 days, Feb has 28 days, March has 31 days... etc Is there ...
    Mike BlezienMike Blezien
    Apr 4, 2006 at 6:49 pm
    Apr 4, 2006 at 10:05 pm
  • Is there a definative way to recreate the gnu `rm -rf` in perl? I've seen a couple of modules that seem to implement something, and a bunch of variations using File::Find, but it just seems overly ...
    Brian McKeeBrian McKee
    Apr 25, 2006 at 7:55 pm
    Apr 26, 2006 at 3:28 pm
  • Hello List, I have a sort() issue that is a bit odd and any input wouls be most appreciated :) The code: use strict; use warnings; ... for my $obj( sort { $a- value() cmp $b- value() $a- ...
    Apr 25, 2006 at 7:23 pm
    Apr 26, 2006 at 3:21 pm
  • Hi, I have a following line/statement stored in variable $test deliver.Admin_Irfan_Project.20060413.212355 i want to split this line in . and store in array. I am using following code my @name = ...
    Irfan J SayedIrfan J Sayed
    Apr 17, 2006 at 8:13 am
    Apr 25, 2006 at 12:47 pm
  • Hi all I seem to be having a few run ins with the "Project Leader", in terms of my coding style. Im very much for modularizing my work - hence the OO concept. That is creating packages using return ...
    Brent ClarkBrent Clark
    Apr 20, 2006 at 2:39 pm
    Apr 23, 2006 at 9:54 am
  • Hi All, I am newbie to PERL.I think this is a very simple question to ask. Is there any way to print a particular bit of a digit after converting to binary form. Thanks in Advance, Praveena
    Praveena VittalPraveena Vittal
    Apr 21, 2006 at 6:26 am
    Apr 21, 2006 at 6:27 pm
  • I'm trying to do a simple file rename and am starting to pull my hair out. # Open the infile for read, no append, no create, no clobber open RIGHTSLISTFILE, "<$rightslistfilename" $rightslistfilename ...
    Apr 14, 2006 at 8:40 pm
    Apr 15, 2006 at 2:21 pm
  • Hi All, How to get date and time in perl ? is there any function for that ? Regards Irfan Sayed
    Irfan J SayedIrfan J Sayed
    Apr 10, 2006 at 9:52 am
    Apr 10, 2006 at 2:49 pm
  • I'm trying to learn web scraping and am stopped at the basic point of scraping a portion of a web page. I'm able to scrape a full page and save it as *.xml or *.htm, and I think I understand regex, ...
    Apr 7, 2006 at 8:15 pm
    Apr 7, 2006 at 10:46 pm
  • Hi, I need to zip my backup dir. so that it will automatically convert my backup dir to backup.zip file can it be happen through perl ? Any sol. on this? Regards Irfan Sayed
    Irfan J SayedIrfan J Sayed
    Apr 7, 2006 at 5:16 am
    Apr 7, 2006 at 8:12 pm
  • based upon the string in a variable, I want to run a particular subroutine: my $var='cat'; .... .... .... $var='fish'; &$var; # I want to run fish if $var is a fish or cat if $var is a cat... sub cat ...
    The GhostThe Ghost
    Apr 3, 2006 at 8:42 pm
    Apr 4, 2006 at 1:40 pm
  • Hi, I have two strings that I want to compute the number of mismatches between them. These two strings are of the "same" size. Let's call them 'source' string and 'target' string. Now, the problem is ...
    Wijaya EdwardWijaya Edward
    Apr 27, 2006 at 12:51 am
    Apr 27, 2006 at 9:24 pm
  • I want to use truncate to delete a matched line out a named.conf file on my DNS box. Here is my code use strict; use warnings; my $file = qq(/usr/local/admin/perl/derek_perl/test); open (FH, "+< ...
    Smith, DerekSmith, Derek
    Apr 23, 2006 at 5:28 pm
    Apr 25, 2006 at 9:57 am
  • Some time ago I asked about a print_r implementation in Perl. print_r: print object structures recursively, as in PHP, see http:// php.net/print_r Because nobody seemed to have a good answer, we ...
    Johannes ErnstJohannes Ernst
    Apr 21, 2006 at 6:15 am
    Apr 21, 2006 at 7:37 pm
  • I have this as a part of my script: $ncfile = `ls -1 $mersea_cat | head -1`; print $ncfile; It prints the desired first file in $mersea_cat, but _before_ that the ls command prints an errormessage to ...
    Bjørge SolliBjørge Solli
    Apr 20, 2006 at 9:09 am
    Apr 21, 2006 at 7:24 am
  • It would also be helpful if a new question without any relation to a previous question were the beginning of a new email thread, rather than being sent as a reply to an email that is part of a ...
    Chad PerrinChad Perrin
    Apr 21, 2006 at 4:22 am
    Apr 21, 2006 at 6:02 am
  • Is there a way to debug concurrent perl programs, i.e. programs that use fork()? E.g. I would like to watch the main process. At a naive try I got strange error messages. - Gergely
    Gergely BudayGergely Buday
    Apr 20, 2006 at 9:15 am
    Apr 20, 2006 at 3:12 pm
  • I'm still hobbled by my thinking in C problem so I'm looking for a way to do this. I'm reading from a file and constructing an array of arrays. Here's an example of what's in the file: net localgroup ...
    Apr 18, 2006 at 3:47 am
    Apr 18, 2006 at 10:02 am
  • Hi Folks, I have a job that takes in an encrypted file and decrypts it using Crypt::GPG. <code for my $encrypted_file (@files) { open(CIPHERTXT, $encrypted_file) or croak "Can't open encrypted_file: ...
    Apr 6, 2006 at 4:20 pm
    Apr 14, 2006 at 7:24 pm
  • I'm trying to write a small word counting script - I'm certain there are zillions out there but it seemed a good learning exercise... Bascially I read in each line from my text file which I want to ...
    Max von SeiboldMax von Seibold
    Apr 13, 2006 at 2:06 pm
    Apr 13, 2006 at 3:40 pm
  • Hello All, Is there anything as 'static variables' in Perl? I have a "utilities.pl" file which has functions commonly used in other perl programs. One of these function needs to create a temporary ...
    Dhanashri BhateDhanashri Bhate
    Apr 11, 2006 at 9:00 am
    Apr 11, 2006 at 9:50 am
  • Hello List, I was wondering when it is appropriate to do multiple shifts on parameters passed to a subroutine and when it is appropriate to just feed it @_. For example, you have: &fancy_sub($a, $b, ...
    Adam WAdam W
    Apr 10, 2006 at 6:54 am
    Apr 11, 2006 at 1:01 am
Group Navigation
period‹ prev | Apr 2006 | next ›
Group Overview
groupbeginners @

159 users for April 2006

Mr. Shawn H. Corey: 79 posts Dr.Ruud: 51 posts John W. Krahn: 50 posts Chad Perrin: 38 posts Jay Savage: 37 posts JupiterHost.Net: 33 posts Tom Phoenix: 30 posts Irfan J Sayed: 28 posts Chas Owens: 26 posts Timothy Johnson: 21 posts Randal L. Schwartz: 20 posts Mazhar: 14 posts Jeff Pang: 13 posts Alan_C: 12 posts Charles K. Clarkson: 12 posts Dhanashri Bhate: 11 posts John Ackley: 11 posts Nishanth ev: 11 posts D. Bolliger: 10 posts Ed: 10 posts
show more