Re: silly beginners problem :)

2002-01-15 Thread John W. Krahn
Martin A. Hansen wrote: hi im trying to make a script to read a textfile with the following format: TITLE Welcome to Carcinoma in Situ i want my script to recognice the TITLE tag and save the following line(s) in $TITLE: heres what i have done: while () { chomp;

silly beginners problem :)

2002-01-15 Thread Martin A. Hansen
hi im trying to make a script to read a textfile with the following format: TITLE Welcome to Carcinoma in Situ i want my script to recognice the TITLE tag and save the following line(s) in $TITLE: heres what i have done: while () { chomp; if (/TITLE\s*([A-Za-z]+)/) {

Re: silly beginners problem :)

2002-01-15 Thread Frank
On Tue, Jan 15, 2002 at 06:23:28PM +0100, Martin wrote: im trying to make a script to read a textfile with the following format: TITLE Welcome to Carcinoma in Situ i want my script to recognice the TITLE tag and save the following line(s) in $TITLE: heres what i have done: while

Re: silly beginners problem :)

2002-01-15 Thread Roger C Haslock
separator, and look for all characters after TITLE\s* - $/ = ''; my $input = ; $input =~ /TITLE\s*(.+)/; print $1; - Roger - - Original Message - From: Martin A. Hansen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, January 15, 2002 5:23 PM Subject: silly beginners problem :) hi im