Using PERL to retrieve MP3s

2008-04-03 Thread Jim
Hi, I am trying to write a PERL script to retrieve a couple of podcasts per week. Using use XML::RSS::TimingBot I can retrieve and print the .rss file, but how do I extract the actual mp3 URL from $response->content? Thank you for you time. Jim -- To unsubscribe, e-mail: [EMAIL PROTEC

Re: Using PERL to retrieve MP3s

2008-04-04 Thread Jim
Thanks all. Can you tell me which is the best repository to use? The ActiveState one does not seem to have most of the modules I need. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

PPM Repository

2008-04-04 Thread Jim
Hi all, I am looking to easily install some modules, like for example Win32::Clipboard, but they don't show with teh standard modules on ActiveState's repository. Are there a couple of better ones I can add? Thanks for your time Jim -- To unsubscribe, e-mail: [EMAIL PROT

Getting more than one match with regexp

2008-04-14 Thread Jim
$url = "http:" . $1 . ".mp3"; } Thanks for your time Regards, Jim -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Getting more than one match with regexp

2008-04-15 Thread Jim
Many thanks! -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: the browser of LWP

2008-08-21 Thread Jim
AFAIK, LWP allows you to write web clients, for fetching data off the WWW. I think your browser choice is not relevent. Jim On Aug 20, 4:26 pm, [EMAIL PROTECTED] (Temple) wrote: > Hello Perl users, > I have some experience with ruby watir > (http://wtr.rubyforge.org/) > I plan to try

Regexp

2008-08-21 Thread Jim
if($content =~ m/$i/) { print "Found Word " . $i . "\n"; } } @WordList might contain up to 1000 or 2000 words, and changes daily, so I don't think regexp::list is the answer. Thank you for your time. Jim -- To unsubscribe, e-mail: [EMAIL PROTE

Re: Regexp

2008-08-21 Thread Jim
I have solved the problem! Thank you for your time. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Could anyone point me to a good site for pearl compiler download.

2008-08-23 Thread Jim
On 21 Aug., 20:04, [EMAIL PROTECTED] (Rich Murphy) wrote: > Could anyone point me to a good site for pearl compiler download. On windows I use the ActiveState distribution. They have a free PERL interpreter too. http://www.activestate.com/Products/activeperl/index.mhtml -- To unsubscribe, e-ma

Re: Regexp

2008-08-23 Thread Jim
In this case my code was actually good, the problem was with the input file whice was, I am embarressed to say, empty. > It would be good if you could explain your solution. This is a list for > teaching > Perl, not just for finding solutions to individual's problems. If you publish > your workin

Help with comparison of variable

2008-09-16 Thread Jim
How come this does not work? if ($file_list =~ $file_to_excl) I expect this to be true if $file_list contains the string in $file_to_excl - what am I missing? I also tried if ($file_list =~ m/($file_to_excl)/) any help? -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e

Help matching with Regular expression

2009-02-07 Thread Jim
How do I match a line ending in ,@@) using a regular expression? Thank you -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Help matching with Regular expression

2009-02-08 Thread Jim
On Feb 7, 5:17 am, rob.di...@gmx.com (Rob Dixon) wrote: > Jim wrote: > > > How do I match a line ending in > > ,@@) > > using a regular expression? > > my $line = "1234567890,@@)\n"; > > if ($line =~ m/,@@\)$/) { >   print "OK\n"; >

Socket IO question

2004-06-01 Thread Jim
Hi I have 2 simple scripts to send short files from a win2k box to HP unix box ( for learning purposes only ). They work fine, but I am looking for ideas on why the client (win2k) needs a sleep statement after each line write. If I leave it out, I get a "Connection reset by peer" on the receiving e

RE: Catching signals

2004-08-17 Thread Jim
> Hi, can you please show me an example of the following signal > catching > scenario: > 1. First Ctrl-C => Just warn and wait for a key-stroke, if > any key other > then Ctrl-C is presses, continue with the program. > 2. If Ctrl-C was pressed again => Try to die gracefully, > meaning do some > cle

RE: Can't kill forked grandchildren when running from shell script

2004-08-17 Thread Jim
> My perl script forks and the child is subsequently replaced by another > (non-Perl) program with exec(). That child has its own subprocess. > > In response to certain events, the parent tries to kill the child (and > its children). > > Currently, my method for doing this is: > > local $SIG{HU

RE: Can't kill forked grandchildren when running from shell script

2004-08-17 Thread Jim
..\n" unless $quiet; > local $SIG{HUP} = 'IGNORE'; > kill HUP => -$$; > last; >} > } until ($kid > 0); > > The problem here is the kill HUP => -$$ only works when the > parent is run > from the command prompt, not when run fr

RE: delete all lines in a file save it come out

2004-08-31 Thread Jim
> Hi , > I have a problem in deleting all the lines in a file and saving it . > Actually my log file keep appending all the messages for that > i need to clean it up i.e delete all lines in it save it . > when i do this initially file shows zero bytes , but as soon > as the next message append

RE: delete all lines in a file save it come out

2004-08-31 Thread Jim
> > On Aug 31, Jim said: > > >open (FILE, "+>", $file) or die "cannot open $file: $!"; > > I think you want "+>>" there, or else it will overwrite the > contents of the file and you won't be able to determine how >

RE: Removing a tempdir's on Windows

2004-09-11 Thread Jim
> temporary directory. The script parses all the logs, dumping > those that are of interest to us for the various parts of the > report to smaller, easier to handle files. I am using the > following statement to create a temporary directory which > works out great, removing most of the file

RE: Regex help

2004-09-13 Thread Jim
=~ s/[[:cntrl:]]//g; $filename =~ s/\s//g; print lc($filename); That help at all? Jim --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.745 / Virus Database: 497 - Release Date: 8/27/2004 -- To unsubscribe, e-mail: [EMA

RE: Regex help

2004-09-13 Thread Jim
> > Hi Jim, > > rather than re-invent the wheel I would prefer if you could > fix this regex I believe it covers all invalid characters one > would encounter > > s/[\w\&%'[EMAIL PROTECTED](\)&_\\+,\.=\[\]]//g; > > I would then use it as a genera

RE: Regex help

2004-09-14 Thread Jim
> So in short the regex must remove any characters from the > anchor text e.g the & in 'News & events' > and any spaces, basically any characters that cannot be used > in a filename if they have been inadvertently entered by the users. What kind of file names? DOS, UNIX, Other? --- Outgoing

RE: split function

2004-09-14 Thread Jim
ngth($string)/8), $string); Thanks Jim --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.745 / Virus Database: 497 - Release Date: 8/27/2004 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail

RE: Binary file and pack... What do I have now ?! Feeling lost...

2004-09-16 Thread Jim
took me a while to learn how to use them properly, in fact I still struggle with it. vec() is even more squirrelly Thanks JIm --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.760 / Virus Database: 509 - Release Date: 9/10/2004 --

RE: Time Skip

2004-09-16 Thread Jim
> > $filename = "data_logfile" .(localtime). ".txt"; open(LOG, > ">>$filename") || die "cannot append: $!"; > > > when I compile the file is says "Invalid argument". This is > because of the colon character. > You have answered your own question :). You can't use the : char in the creatio

RE: POSIX module

2004-09-29 Thread Jim
> Hi Perlers, > > I've seen a lot of tutorial or example code dealing with the > POSIX module that does something like this: > > use POSIX ':sys_wait_h'; > > What does the ':' mean/do in the above line? > Besides googling for it, try reading: perldoc perlipc perldoc perldoc -f waitpid perl

RE: connect through socks

2004-09-30 Thread Jim
> > > Hi perlers, > > > > anyone knows how to connect to a website and download it > through socks > > (ver 4,5) ? I tried IO::Socket::Socks and Net::SOCKS, but I > can't get > > them to work. > > I know it can be done via 'LWP::UserAgent'. Not sure via a > socket though. you could always

RE: Passing shell variables to PERL

2004-10-05 Thread Jim
ame in perl with the special hash named %ENV. for instance: print $ENV{'SHELL'} or you can use the env module: perldoc -f env THanks Jim --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.772 / Virus Database: 519 - Rel

RE: Contact Form/Email Capability

2004-10-07 Thread Jim
MTP Simpley google for these and you should find plenty of examples. I have some example scripts as well I can send you if you like HTH, Jim --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.772 / Virus Database: 519 - R

RE: Re Finding file

2004-10-07 Thread Jim
> print "$File::Find::name\n"; > > }, > 'c:\Documents and Settings'); I don't seen anywhere in this script where you actually attempt to delete or rename anything Did I miss something? and why are you trying to open the file, if you are just trying to delet

RE: help with perl/cgi creating a html code with pull down menu

2004-10-18 Thread Jim
> Hi: I have created a perl cgi script to grab two string > inputs from users. The script shown below expects the user to > type in the value. I would like to change this and give the > user a pulldown menu to pick from a list of items. Could > somebody provide help with what I need to chang

RE: .txt To Mysql.......roy

2004-10-19 Thread Jim
ou are going to be doing this kind of stuff, you had better start learning Perl DBI. Google for it, install it and read and learn.. Jim --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.772 / Virus Database: 519 - Release Date:

Determine the Binary format of a file

2004-10-26 Thread Jim
Hi I have a binary file that I have been tasked to discover the format of and somehow convert the records to readable text. Is there any way I can find out what binary format the file is in, so I can create an template for unpack() to convert the binary to text? Thanks Jim --- Outgoing mail is

RE: Determine the Binary format of a file

2004-10-27 Thread Jim
> > The best place to start is with the `file` command, and the > magic numbers behind it, which not nearly enough people know > about these days. Hi Sorry to so long to post back. I did not have access to the list today at work I should have mentioned, I tried unix file command and it only r

RE: Determine the Binary format of a file

2004-10-27 Thread Jim
> If you do manage to find out the file contains some sort of "standard" > binary format per the 'file' command, you can also visit > http://www.wotsit.org/ which contains "very detailed" > information about the binary structure for hundreds of > different known file formats. > Nice link. Un

RE: Determine the Binary format of a file

2004-10-27 Thread Jim
> Any ideas where to start? Generally I try and determine > record size and delimiter first. Are they fixed length > records? newline or null delimited? CSV ?? > > more input. > I have no idea. It does not seem to be newline delimited (. Is there some trick to try to determine the record s

RE: Determine the Binary format of a file

2004-10-27 Thread Jim
> There are a lot of different versions of the magic number > database floating around out there, but if the file format > you're dealing with is some kind of weird proprietary thing, > then you may be stuck... Yea, I am getting that feeling :( > > At that point, the next recourse I can thi

RE: Determine the Binary format of a file

2004-10-27 Thread Jim
> > Does "strings file" give you any clues? > nope, just the ascii header I already know about. I just downloaded a ultra edit, I will see what that does [EMAIL PROTECTED] ~]$ strings LPAS188.RED | more 2004 by Mortgage Information Corp, San Francisco, CA 2004080 00Prime ERED MARKET 65533 1

RE: Determine the Binary format of a file

2004-10-27 Thread Jim
> > Tried that and also tried the unix strings command. No help > > I didn't mean to suggest that it would be *easy*, but at this > point I think your only way of getting any traction -- short > of getting the vendor to help you or getting your new vendor > to take a look -- is to just sit do

RE: Preventing shell redirection from creating empty file

2004-10-29 Thread Jim
> > On Tue, 26 Oct 2004, Dan Fish wrote: > > > system("myscript.pl arg1 arg2 > myfile.txt"); > > > > What is the easiest way to prevent "myfile.txt" from being > created if > > the script dies or produces no output? (It seems the shell > will always > > create myfile.txt, regardless) > >

RE: DN <-> IP

2004-10-31 Thread Jim
> I just wrote small script to resolve domain name on basis IP address and vice versa, do you think it is the best and fastest way? Thanks. > my ($host, $ip); > > $host = 'www.google.com'; > $ip = inet_ntoa(inet_aton($host)) || 'no IP'; print "$host: $ip\n"; > > $ip = '213.160.174.5'; > $host = g

RE: How to get name of script

2004-11-03 Thread Jim
> How do I get the name of the current PERL script I am > running? The answer to this question may be very obvious but > I can't seem to locate it in my books or other resources. > > Thanks in advance, > # strip the path info to the script: (my $prog = $0) =~ s/^.*[\\\/]//; --- Outgoing ma

RE: Reading external file and writing out individual files

2004-11-09 Thread Jim
> How would I go about reading in an external file and then > based on the search criteria write out individual files. > Basically I want to split one big chunk into smaller chunks. > > The file gets opened and then I want to search for the first > occurence of and pickup up everything until I

RE: Why doesn't this work?

2004-11-09 Thread Jim
> The following subroutine should take an input path (Dir0), > process that directory by recursively calling itself on > subdirectories or processing any files it contains. The > problem I am experiencing is that in the following example > file structure it process Dir1 correctly, but after

RE: Unlink ?

2004-11-15 Thread Jim
> I want to use the unlink command to programmatically delete files. > > I have modified this code snippet but it no longer works, I > suspect that it's because unlink returns the number of deleted files. > > my $cmd = qq[unlink $srcFile]; > $debug->printlog("command: $cmd"); > my $cmdR

RE: Building Network Redundancy into a Perl Client

2004-12-04 Thread Jim
> I am trying to implement redundancy in a client application > that I am writing so that I can have a primary server and a > backup server. The client is tailing a logfile and sends > results to a server for processing, at the end of the tail > loop it sends data to a function that tries to e

RE: Building Network Redundancy into a Perl Client

2004-12-06 Thread Jim
> -Original Message- > From: Joshua Berry [mailto:[EMAIL PROTECTED] > Sent: Monday, December 06, 2004 10:01 AM > To: Jim > Cc: [EMAIL PROTECTED] > Subject: RE: Building Network Redundancy into a Perl Client > > I don't think that it is possible to do with

RE: :Socket::UNIX questions

2004-12-31 Thread Jim
> > I am working with UNIX Sockets and have some questions that I > cant seem to find answers to on the web. > > 1: Are UNIX sockets bi-directional? > > 2: If so, what is the proper way to 'setup' the connection? > (will post what I have below) > > 3: Do UNIX sockets have less overhead tha

RE: Array question

2005-01-08 Thread Jim
> > Can anyone help with this > I have the following array: > 1,1040209458 > 2,1040328655 > 3,1040847094 > 4,1041030406 > 5,1042093756 > I need to create a script that goes through this > array(@temp_array), and > creates various output fi

RE: Array question

2005-01-09 Thread Jim
> > > > Can anyone help with this > > I have the following array: > > 1,1040209458.. > > WRITE CONTENTS OF AN ARRAY TO OUTPUT FILES > > for ($i=0; $i < $num_of_files; $i++){ > > open(OUT,">$file_$seq_num.txt"); > > foreach $item (@temp_array){ > >

Printing after expression match

2006-07-12 Thread Jim
I can't believe I didn't find this through searching. While looping through a file,array,hash etc.. how can I start printing only after a certain expression matches. in other words how can I skip the lines in the data until an expression match. Thanks -- # want to print lines from apple on down

RE: Printing after expression match

2006-07-12 Thread Jim
> > > > ># want to print lines from apple on down > > > >while ($line = ) { > > next until $line =~ /^banan/; > > print $line; > >} > > > > Hello,how about this? > > my $ok; > while (){ > $ok = 1 if /^banan/; > print if $ok; > } > yes that works, thanks. Are there oth

RE: Printing after expression match

2006-07-12 Thread Jim
> > > Try: > > #!/usr/bin/perl > > use strict; > use warnings; > > my $print_line = 0; > > while( ){ > if( /banana/ ){ > $print_line = 1; > }elsif( $print_line ){ > print; > } > } > > __DATA__ > orange > peach > banana > apple > pear > mango > > > -- Thanks, this is simila

RE: Printing after expression match

2006-07-13 Thread Jim
> > while ( ) { > print if /^apple/ .. eof; > } > > > > John > -- > use Perl; > program > fulfillment > Thanks John. I prefer this way. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Net:SSH:Perl error

2006-09-06 Thread Jim
ug the archives but not have been able to find out why this happens Thanks for any help, Jim -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>

floating point precision

2010-09-01 Thread Jim
changing it to "0.00" if it matches. I don't like either of these solutions. How do others deal with this? Thanks, Jim -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: floating point precision

2010-09-01 Thread Jim
On 9/1/2010 5:04 PM, Chas. Owens wrote: On Wed, Sep 1, 2010 at 16:46, Jim wrote: Can anyone comment how they handle floating point precision situations like this? snip I don't like either of these solutions. How do others deal with this? snip Short answer: floating point numbers suck

Re: floating point precision

2010-09-02 Thread Jim
ike is the final -0.00. When the answer due to fp error is slightly less than 0.00. Putting some check on that whenever real numbers are added is a drag. But thanks again for all the feedback. Jim -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: floating point precision

2010-09-02 Thread Jim
On 9/2/2010 2:51 PM, Ruud H.G. van Tol wrote: On 2010-09-02 15:32, Jim wrote: I was hoping I'd see some answer like... oh yeah... perl is smart enough to handle that for you if you are willing to accept a performance hit... My "bigrat" was meant like that. Did you already try

Re: floating point precision

2010-09-02 Thread Jim
On 9/2/2010 4:15 PM, Jim Gibson wrote: On 9/2/10 Thu Sep 2, 2010 12:52 PM, "Jim" scribbled: On 9/2/2010 2:51 PM, Ruud H.G. van Tol wrote: On 2010-09-02 15:32, Jim wrote: I was hoping I'd see some answer like... oh yeah... perl is smart enough to handle that for you if you

Re: Permission bit translator?

2011-03-10 Thread jim
ccess are allowed 4 r-- 100 Read access is allowed only 5 r-x 101 Read and execute access are allowed 6 rw- 110 Read and write access are allowed 7 rwx 111 Everything is allowed hth Jim -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

ip address substitution

2011-03-16 Thread Jim
ess_regexp =~ s/\./\\./ig; $read_line =~ s/(\D*)$old_ip_address_regexp(\D*)/$1$new_ip_address$2/ig; Thanks, Jim -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

problem with simple pattern matching

2007-08-29 Thread Jim
valuse found in those first 2 successes and writes them out after that the sub below is called in a for loop which pulls out some new data to fill the args Thanks Jim the lines im trying to match are #! DATASET="C:\jim\MinePlan\StratMinePlan\Data_In\2007\2 year detailed stage plan\DGN_I

basic regex question

2007-10-10 Thread Jim
Hi Everyone, I am trying to match file & subdir names from a back tic generated list. I never find anything and there are files in the directory with a correct name. but if i make up a list to use as filenames it works as i expect ... any insight greatly appreciated thanks Jim #!/usr/bin/

Re: checking for file existence

2013-09-25 Thread Jim
Perhaps file or directory permissions related to the file being checked based on the user running the perl script? Jim On 9/25/2013 4:07 PM, Peter Ezetta wrote: Hi Renato, Welcome to Perl and to the list! I took a quick run through your code, and it's working fine for me. Are you ca

skip/delete lines with dup keys

2005-07-26 Thread Jim
(need to remove lines with dup key fields). The code below seems to work, but there must be a better way. Thanks for any help Jim - # file already sorted by $id my $cur_id = ''; while () { chomp; ($id,$score,$bal) = split (/,/, $_);

RE: skip/delete lines with dup keys

2005-07-27 Thread Jim
-- > > > > # file already sorted by $id > > my $cur_id = ''; > > while () { > > chomp; > > ($id,$score,$bal) = split (/,/, $_); > > next if $cur_id == $id; > > print OUT "$id,$score,$bal\n"; > > $cur_id = $id; > > } > > Don't fix it if it's not broken. :-) > > Thanks

RE: Read a single line in a file.

2005-07-30 Thread Jim
> Original Message- > From: Umesh T G [mailto:[EMAIL PROTECTED] > > Sent: Friday, July 29, 2005 3:47 PM > To: beginners@perl.org > Subject: Read a single line in a file. > > > Hello List, > > I have a file with multiple lines. I want to read only the first line. > > and a particular

Passing nested hash to a function

2005-08-13 Thread Jim
Hi I am trying to pass a HoH structure to a function which should iterates the contents of the HoH. From the docs I read, it should work, but I get no output. What am I missing? Thanks, Jim %hoh = ( B1 => { a => 'fox',

RE: Passing nested hash to a function

2005-08-13 Thread Jim
> Perhaps this is what you want? > > sub func { > my $h = shift; > for $k (keys %$h) > { > print "$k\n"; > for $n ( keys %{ $h->{$k} } ) > { > print "$n => $h->{$k}{$n}\n"; > } > > Read: perldoc perldsc > Hope that helps. > Thanks. That seems to work. It was just

RE: Directory Size

2005-08-28 Thread Jim
> -Original Message- > From: Nick [mailto:[EMAIL PROTECTED] > Sent: Sunday, August 28, 2005 1:26 PM > To: Perl Beginners > Subject: Directory Size > > Hi All, > > Is there a way to get an entire directory and all > sub-files/folders size in Perl? Basicly, I need the Perl > version o

RE: Hash of Arrays

2005-09-23 Thread Jim
> > The part that confuses me is: > > ($who, $rest) = split /:\s*/, $line, 2; > > I understand that it takes the input and splits it into two > parts along the regular expression, but I can't figure out > what the 2 means. > split the expression into a maximum of 2 perldoc -f split --

Help understanding VEC

2006-03-26 Thread Jim
27;; -- I understand that it is testing the bit string in the first octet of the ipaddr to determine it's address class but not quit sure how. I think this code came from John Krahn in response to a post of mine a few years ago. Thanks, Jim -- To unsubscribe, e-mail: [EMAIL PROTE

RE: Help understanding VEC

2006-03-27 Thread Jim
> > > I am trying to understand how vec() is works in the code below > > Have you seen the documentation in the perlfunc manpage? > > perldoc -f vec > > If you still have questions, after seeing the docs, please ask again. > Hope this helps! > Yes, I have read it already. Thanks -- T

RE: Help understanding VEC

2006-03-27 Thread Jim
> Jay Savage wrote: > > > > > > > You might also want to keep in mind that the BITS must be a > power of 1 > It must be a power of 2. > > > from one to 32, and that vec() is lvaluable, but you don't need to > > know that to look at the code here. > > > > vec( $address, 7, 1 ) > >

RE: Local Server/Perl/HTML question...

2006-04-04 Thread Jim
> > I have just downloaded xitami and gotten it configured - I > hope correctly - on my W2K professional system. I've > installed PERL as well. > I put a PERL .PL in c:\xitami\cgi-bin and tried running it > by using my IE browser to run it. > > I'm sure the program runs as it creates thre

Regex Help

2006-04-18 Thread Jim
i am trying to match a '!' followed by any char but a '!' or no chars (string is only a '!') this is what I have and it is not working: $str = "!!"; # this is not working. it is matching "!!" print "$str\n" if $str =~ /\![^!]*/; Thanks for any help -- To unsubscribe, e-mail: [EMAIL PROTECTE

RE: Regex Help

2006-04-18 Thread Jim
> > You need to anchor your regex. Your regex is matching '!!' because it > is matching an exclamation point followed by zero or more non > exclamation-point characters anywhere in the string. > > Thus the first '!' is matching the regex, and the second '!' is outside > of your match. yep, fo

Re: Perl Unix Binary Files

2002-11-03 Thread Jim
:crlf" for "text" mode. If the DISCIPLINE is omitted, it defaults to ":raw". | I would suggest taking a look at Storable. | | > All e-mails and attachments are certified virus free! | | Phew! -- - Jim -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: Perl Unix Binary Files

2002-11-05 Thread Jim
On Sunday 03 November 2002 11:25, John Pitchko wrote: Sorry this took me so long to respond to. Yes, that is part of if not the full answer to your question. You make the data binary before writing it to a file. - Jim | Ok so then how do I make my data binary? Use pack() and unpack

Re: [mail_lists] RE: Perl Cgi/ Why?

2002-12-12 Thread Jim
st for webdev. However, now, I would have to say that Perl is just as good as PHP in the webdev dept and in some cases maybe a little better and in some cases not. *shrug* how 'bout that for ambiguity... =] - Jim | | > -Original Message- | > From: [EMAIL PROTECTED] [mailto

Re: [mail_lists] perl script to convert dos newlines to unix newlines...

2002-12-14 Thread Jim
On Friday 13 December 2002 05:42, you wrote: on the command line do this: perl -p -i -e 's/\r\n/\n/g' file_to_remove_those_pesky_^Ms_from Perl one-liners rule. :) This will do it without making the second file. - Jim | hey, | i wanna make a perl script that will convert those st

Re: [mail_lists] Re: perl script to convert dos newlines to unix newlines...

2002-12-14 Thread Jim
On Friday 13 December 2002 12:18, Gary Stainburn wrote: This still doesn't answer his question. He doesn't want to take up 20 Mb's of hdd space trying to do the edit. :) btw, in a regex \r\n works fine. :) - Jim | On Friday 13 Dec 2002 10:42 am, christopher j bottaro wrote:

Re: [mail_lists] RE: Excel

2002-12-19 Thread Jim
. - Jim | I found a couple modules. But they all seem to either for getting data | from excel or creating a new excel worksheet. I need to insert data into | an excel spreadsheet that already contains data,and several worksheets. | | > -Original Message- | > From: NYIMI Jose (BMB) [

Tk::Balloon Question

2003-02-06 Thread Jim
f the main window. Can anyone advise me on getting balloons to show up properly the first and every time? Thanks, Jim use Tk; use Tk::Balloon; my $mw = MainWindow->new; my $canvas = $mw->Canvas( )->pack( -expand=>1, -fill=>'both', ); my $id = $canvas-

Re: [mail_lists] help on manipulating string length

2003-04-02 Thread Jim
/(.*?)\s+/g) + 1;     if ( /visualid/i )     {         print "$_\t    \n";         next;     }     if ( $numwords < 2 )     {         print "\t\t    $_\n";     }     else     {         print $_,"\n";     } } VISUALID             123456              1023

Re: [mail_lists] RE: Problem with script.

2003-04-02 Thread Jim
loop. Functions are a beautiful thing that assist in the creation of your program and allows for brevity and ease of maintenance. Sorry...I just wanted to put my $.02 in. ;) -- - Jim -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: [mail_lists] Re: Php perl?

2003-04-02 Thread Jim
I just love Perl. I *need* to learn more C. I have to say that I really like the windows PHP documentation (*.chm file). When I was using Windows that was a HUGE plus to PHP. Is there a such thing for Perl? I've never seen it. PHP and Perl kick any microsoft language's butt when it

Re: Php Perl?

2003-04-02 Thread Jim
I just love Perl.  I *need* to learn more C.  I have to say that I really like the windows PHP documentation (*.chm file).  When I was using Windows that was a HUGE plus to PHP.  Is there a such thing for Perl?  I've never seen it. PHP and Perl kick any microsoft language's butt when it

Re: [mail_lists] RE: Php perl?

2003-04-02 Thread Jim
I) related activitiy. I do have to admit that PHP's build is ridiculously difficult compared to Perl. | Perl has the LWP family of modules for doing HTTP client applications, as | well as various HTML and XML parsing modules that can be used for what | you're describing. -- - Jim

regex $1 not updating?

2003-04-04 Thread Jim
et $1 because it is a read-only variable. This doesn't even work if I change the second $var to $var2 because of course $1 is the same the way through. VERY frustrating. -- - Jim -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: [mail_lists] Re: looking for help with Net::IRC

2003-04-04 Thread Jim
w how to detect the modes of a channel or its | users. RFC 2810-2812 either do not provide such an option or I just | cannot find it. :) | | Best regards, | oliver. -- - Jim -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: [mail_lists] Re: regex $1 not updating?

2003-04-04 Thread Jim
On Friday 04 April 2003 14:34, John W. Krahn wrote: | Jim wrote: | > I've never encountered this before but I have to be doing something | > wrong. | | Yes, you are. This is the documented behaviour of the numeric variables | and is why we always tell beginners to use them only if

Re: [mail_lists] Re: regex $1 not updating?

2003-04-04 Thread Jim
Thanks for the assistance guys. - Jim | Jim wrote: | > I've never encountered this before but I have to be doing something | > wrong. | > | > snippet of code: | > | > ]$ perl -e ' | > | > > $var = "Company Online (Company

Re: [mail_lists] how to count?

2003-06-08 Thread Jim
k it will. If this isn't what you were asking then I truly have no clue what your goal is. See if what I clipped up there will do what you want. - Jim | Hi! | | I am not sure if this can be done or not, but I want to create a counter on | the fly so to speak. | | for

sleep () and print ()

2001-06-16 Thread Jim Gallott
pause one second, do the 2 line returns, wait another second, then do all the printing together. I obviously have something wrong, but don't know what. Section of code: sleep (1); print "\n\nThe result is:"; sleep (1); print "\n\nI was home alone. etc, etc. -- Jim Gallot

Re: sleep () and print ()

2001-06-16 Thread Jim Gallott
buffering. You can switch some of this > off in perl by specifying: > > $| = 1; -- Jim Gallott West Meadows Farm, New Haven VT [EMAIL PROTECTED] http://www.westmeadowsfarm.com

Re: problems with chmod

2001-07-07 Thread Jim Conner
ons in >a mkdir statement if they are more restrictive than my umask. otherwise >the perms default to my umask. >i know i can get past this by following the mkdir statement with a chmod, >but i just wanted to verify that my logic on this one is correct. - Jim -~-~-~-~-~-~-~-~-~-~-~

Re: Editor

2001-07-07 Thread Jim Conner
quot;:syn-on" isn't implemented, huh? Guess I'm stuck with some weird version. > > >-Original Message- > >From: Matija Papec [mailto:[EMAIL PROTECTED]] > >Sent: Friday, July 06, 2001 3:06 PM > >To: [EMAIL PROTECTED] > >Subject: Re: Editor > &

  1   2   3   4   5   6   7   8   9   10   >