Front page | perl.beginners |
Postings from April 2003
help with substiution
Thread Previous
|
Thread Next
From:
Ravi Malghan
Date:
April 28, 2003 10:29
Subject:
help with substiution
Message ID:
20030428172939.59541.qmail@web41303.mail.yahoo.com
Hi: I am not able to perform a substition in the
following string
$_ = "attr1 val1\nattr2 val2\nattr3 val3";
I want to substitute "attr2 val2" with "attr2 val4"
s/.*(attr2 .*)\nattr3.*/"attr2 val4"/;
The above substitution does not seem to be working.
Could somebody help?
Thanks
Ravi
__________________________________
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
http://search.yahoo.com
Thread Previous
|
Thread Next