Search Discussions
-
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 Hall
Apr 26, 2006 at 8:19 pm
May 3, 2006 at 9:20 am -
32
Perl help
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 Sayed
Apr 5, 2006 at 4:47 pm
Apr 26, 2006 at 4:22 am -
27
golf
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 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 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 ...
Siegfried
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 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 Turnbull
Apr 4, 2006 at 2:36 am
Apr 4, 2006 at 12:58 pm -
18
Chomp method
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 ...AndrewMcHorney
Apr 27, 2006 at 5:51 am
Apr 28, 2006 at 5:40 pm -
16
Regex help
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 ...Owen
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 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 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 ...
Mazhar
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 ...
JupiterHost.Net
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 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 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 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 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 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 ...
Ed
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 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 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 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, 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 ...
Mazhar
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 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 ...
Alan_C
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 ...
Mazhar
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 ...
Kc68
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 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 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- ...
JupiterHost.Net
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 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 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 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 ...
Ed
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 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, ...
Kc68
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 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 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 Edward
Apr 27, 2006 at 12:51 am
Apr 27, 2006 at 9:24 pm -
5
truncate
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, Derek
Apr 23, 2006 at 5:28 pm
Apr 25, 2006 at 9:57 am -
5
print_r
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 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 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 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 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 ...
Ed
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: ...
RICHARD FERNANDEZ
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 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 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 W
Apr 10, 2006 at 6:54 am
Apr 11, 2006 at 1:01 am
159 users for April 2006
Archives
- May 2016 (29)
- March 2016 (38)
- February 2016 (66)
- January 2016 (62)
- December 2015 (36)
- November 2015 (59)
- October 2015 (35)
- September 2015 (32)
- April 2015 (18)
- March 2015 (101)
- February 2015 (74)
- January 2015 (99)
- December 2014 (74)
- November 2014 (65)
- October 2014 (47)
- September 2014 (66)
- August 2014 (68)
- July 2014 (171)
- June 2014 (85)
- May 2014 (126)
- April 2014 (36)
- March 2014 (162)
- February 2014 (154)
- January 2014 (94)
- December 2013 (42)
- November 2013 (71)
- October 2013 (192)
- September 2013 (143)
- August 2013 (114)
- July 2013 (141)
- June 2013 (201)
- May 2013 (163)
- April 2013 (90)
- March 2013 (125)
- February 2013 (150)
- January 2013 (185)
- December 2012 (120)
- November 2012 (101)
- October 2012 (117)
- September 2012 (180)
- August 2012 (319)
- July 2012 (170)
- June 2012 (223)
- May 2012 (249)
- April 2012 (298)
- March 2012 (311)
- February 2012 (261)
- January 2012 (155)
- December 2011 (282)
- November 2011 (266)
- October 2011 (316)
- September 2011 (369)
- August 2011 (371)
- July 2011 (310)
- June 2011 (392)
- May 2011 (434)
- April 2011 (630)
- March 2011 (440)
- February 2011 (282)
- January 2011 (419)
- December 2010 (319)
- November 2010 (314)
- October 2010 (360)
- September 2010 (256)
- August 2010 (223)
- July 2010 (340)
- June 2010 (298)
- May 2010 (483)
- April 2010 (683)
- March 2010 (480)
- February 2010 (339)
- January 2010 (322)
- December 2009 (531)
- November 2009 (558)
- October 2009 (375)
- September 2009 (449)
- August 2009 (497)
- July 2009 (428)
- June 2009 (306)
- May 2009 (293)
- April 2009 (362)
- March 2009 (477)
- February 2009 (467)
- January 2009 (408)
- December 2008 (405)
- November 2008 (545)
- October 2008 (770)
- September 2008 (662)
- August 2008 (663)
- July 2008 (773)
- June 2008 (730)
- May 2008 (650)
- April 2008 (791)
- March 2008 (692)
- February 2008 (399)
- January 2008 (694)
- December 2007 (581)
- November 2007 (688)
- October 2007 (882)
- September 2007 (709)
- August 2007 (1,243)
- July 2007 (849)
- June 2007 (898)
- May 2007 (796)
- April 2007 (587)
- March 2007 (705)
- February 2007 (521)
- January 2007 (578)
- December 2006 (565)
- November 2006 (555)
- October 2006 (704)
- September 2006 (734)
- August 2006 (725)
- July 2006 (884)
- June 2006 (681)
- May 2006 (703)
- April 2006 (889)
- March 2006 (724)
- February 2006 (607)
- January 2006 (588)
- December 2005 (684)
- November 2005 (664)
- October 2005 (682)
- September 2005 (616)
- August 2005 (743)
- July 2005 (716)
- June 2005 (670)
- May 2005 (809)
- April 2005 (830)
- March 2005 (1,020)
- February 2005 (740)
- January 2005 (784)
- December 2004 (873)
- November 2004 (910)
- October 2004 (1,242)
- September 2004 (936)
- August 2004 (911)
- July 2004 (1,101)
- June 2004 (1,026)
- May 2004 (945)
- April 2004 (1,161)
- March 2004 (1,485)
- February 2004 (1,608)
- January 2004 (1,512)
- December 2003 (1,607)
- November 2003 (1,437)
- October 2003 (1,314)
- September 2003 (1,382)
- August 2003 (1,351)
- July 2003 (1,559)
- June 2003 (1,576)
- May 2003 (1,586)
- April 2003 (1,600)
- March 2003 (1,731)
- February 2003 (1,641)
- January 2003 (2,020)
- December 2002 (1,360)
- November 2002 (1,198)
- October 2002 (1,677)
- September 2002 (1,905)
- August 2002 (1,685)
- July 2002 (1,975)
- June 2002 (1,900)
- May 2002 (2,332)
- April 2002 (2,098)
- March 2002 (1,658)
- February 2002 (2,237)
- January 2002 (2,304)
- December 2001 (1,568)
- November 2001 (1,823)
- October 2001 (1,712)
- September 2001 (1,289)
- August 2001 (1,993)
- July 2001 (2,424)
- June 2001 (3,399)
- May 2001 (1,797)
- April 2001 (650)