Re: Finding words between words...

2002-03-11 Thread Boris Zentner
Hi, > I have some text here that I have placed in a string. I want to be able > to extract words between text of my choice. For example in the > string... > > $string = "Hello world In: crud all Your."; > > ($mytext) = $string =~ /In:(.*)Your/; > > The above works fine but how can I tell my re

RE: Finding words between words...

2002-03-11 Thread Timothy Johnson
search on google or perlre on "perl greedy regular expressions" for more info. -Original Message- From: Daniel Falkenberg To: Timothy Johnson Cc: [EMAIL PROTECTED] Sent: 3/10/02 4:05 PM Subject: RE: Finding words between words... Hello all, I have some text here that I have p

RE: Finding words between words...

2002-03-10 Thread Daniel Falkenberg
Hello all, I have some text here that I have placed in a string. I want to be able to extract words between text of my choice. For example in the string... $string = "Hello world In: crud all Your."; ($mytext) = $string =~ /In:(.*)Your/; The above works fine but how can I tell my regex to st

RE: Finding words between words...

2002-03-08 Thread Timothy Johnson
That makes sense. Thanks. -Original Message- From: Jason Larson [mailto:[EMAIL PROTECTED]] Sent: Friday, March 08, 2002 8:53 AM To: [EMAIL PROTECTED]; Timothy Johnson Cc: 'Daniel Falkenberg '; [EMAIL PROTECTED] Subject: RE: Finding words between words... > -Ori

RE: Finding words between words...

2002-03-08 Thread Jason Larson
> -Original Message- > From: Jeff 'japhy' Pinyan [mailto:[EMAIL PROTECTED]] > Cc: 'Daniel Falkenberg '; [EMAIL PROTECTED] > Subject: RE: Finding words between words... > > > On Mar 7, Timothy Johnson said: > > >From: Jeff '

RE: Finding words between words...

2002-03-07 Thread Jeff 'japhy' Pinyan
On Mar 7, Timothy Johnson said: >From: Jeff 'japhy' Pinyan > >> ($btwn) = $str =~ /In:(.*)Your/; > >Out of curiosity, what happens if you leave off the parentheses on $btwn? You try it. ;) I suggest you read "'List' is a Four-Letter Word", which you can find at http://www.pobox.com/~japhy/a

Re: Finding words between words...

2002-03-07 Thread Sudarsan Raghavan
riginal Message- > From: Jeff 'japhy' Pinyan > To: Daniel Falkenberg > Cc: Timothy Johnson; [EMAIL PROTECTED] > Sent: 3/7/02 10:07 PM > Subject: RE: Finding words between words... > > On Mar 8, Daniel Falkenberg said: > > >That is very similar to what I am l

RE: Finding words between words...

2002-03-07 Thread Timothy Johnson
Out of curiosity, what happens if you leave off the parentheses on $btwn? -Original Message- From: Jeff 'japhy' Pinyan To: Daniel Falkenberg Cc: Timothy Johnson; [EMAIL PROTECTED] Sent: 3/7/02 10:07 PM Subject: RE: Finding words between words... On Mar 8, Daniel Falke

RE: Finding words between words...

2002-03-07 Thread Jeff 'japhy' Pinyan
On Mar 8, Daniel Falkenberg said: >That is very similar to what I am looking at doing. The only problem is >I don't want to replace anything in between In: and Your; I just want >to extract anything between In: and Your and store it as a variable. ($btwn) = $str =~ /In:(.*)Your/; -- Jeff "

RE: Finding words between words...

2002-03-07 Thread Daniel Falkenberg
ailto:[EMAIL PROTECTED]] Sent: Friday, 8 March 2002 11:44 AM To: Daniel Falkenberg; [EMAIL PROTECTED] Subject: RE: Finding words between words... I think this will do what you're asking, but I can't test it. $line =~ s/In:(.*)Your/In:($newstring)Your/; # substitute In: followed b

RE: Finding words between words...

2002-03-07 Thread Timothy Johnson
lto:[EMAIL PROTECTED]] Sent: Thursday, March 07, 2002 2:55 PM To: [EMAIL PROTECTED] Subject: Finding words between words... Hey all, Does any one know how I would go about finding everything between the words of... In: Your? So if I have a sentance with the following... Hello all this In: Am

Finding words between words...

2002-03-07 Thread Daniel Falkenberg
Hey all, Does any one know how I would go about finding everything between the words of... In: Your? So if I have a sentance with the following... Hello all this In: America (New York) Your So is there some perl code that will extract America (New York). Keep in mind tha t everything betwee