Re: Re: match and grab

2006-09-29 Thread Tom Phoenix
On 9/28/06, Rob Dixon <[EMAIL PROTECTED]> wrote: But presumably it wasn't called 'indirect object notation' back then? Sure it was. Larry is a linguist, and he saw the filehandle as being the 'indirect object' in a sentence in which print/printf is the verb and some data are the direct object.

Re: match and grab

2006-09-28 Thread Rob Dixon
Rob Dixon wrote: > > John W. Krahn wrote: >> >> Rob Dixon wrote: >>> >>> John W. Krahn wrote: perldoc -f print print FILEHANDLE LIST print LIST print Prints a string or a list of strings. Returns true if successful. FILEHANDLE may be a scalar variable name, in

Re: match and grab

2006-08-02 Thread Rob Dixon
John W. Krahn wrote: >>> >>>perldoc -f print >>> print FILEHANDLE LIST >>> print LIST >>> print Prints a string or a list of strings. Returns true if >>> successful. FILEHANDLE may be a scalar variable name, >>>in which >>> case the variable contai

Re: match and grab

2006-08-02 Thread John W. Krahn
Rob Dixon wrote: > John W. Krahn wrote: >> >> Rob Dixon wrote: >> >>> If you miss out the comma with >>> >>> print $1 "\n" >>> >>> then Perl looks at this as a method call on $1 as an IO::Handle >>> object, or >>> >>> $1->print("\n"); >> >> >> No. >> >> perldoc -f print >>print FILEHANDLE

Re: match and grab

2006-08-02 Thread Rob Dixon
John W. Krahn wrote: Rob Dixon wrote: If you miss out the comma with print $1 "\n" then Perl looks at this as a method call on $1 as an IO::Handle object, or $1->print("\n"); No. perldoc -f print print FILEHANDLE LIST print LIST print Prints a string or a list o

Re: match and grab

2006-08-02 Thread John W. Krahn
Rob Dixon wrote: > > If you miss out the comma with > > print $1 "\n" > > then Perl looks at this as a method call on $1 as an IO::Handle object, or > > $1->print("\n"); No. perldoc -f print print FILEHANDLE LIST print LIST print Prints a string or a list of strings

Re: match and grab

2006-08-02 Thread Rob Dixon
Tim Wolak wrote: > >On Wed, 2006-08-02 at 17:05 +0100, Rob Dixon wrote: > >>Tim Wolak wrote: >> > >> > I am writing a script to monitor a file and if a line is matched write >> > it to a file, then grab the IP address from that line and write it to >> > another file. As I'm ok on working with the

Re: match and grab

2006-08-02 Thread Rob Dixon
Tim Wolak wrote: > > I am writing a script to monitor a file and if a line is matched write > it to a file, then grab the IP address from that line and write it to > another file. As I'm ok on working with the files, I need a little help > as to how to get the IP address out of the line of text i

match and grab

2006-08-02 Thread Tim Wolak
Hello all, I am writing a script to monitor a file and if a line is matched write it to a file, then grab the IP address from that line and write it to another file. As I'm ok on working with the files, I need a little help as to how to get the IP address out of the line of text into a variable f