All tried performing a regex over multi-line text like so
Data has spaces at the beginning
Basically trying to regex over mutliple lines, but regex returns nothing, works fine if it was just /Name=(.+)/
Also tried the /m modifier with /^\s+Name=(.+)^\s+Work=(.+)/
Am I understanding the /s and /m modifiers correctly?
Code:
while (<DATA>){
print "$1\t$2" if /Name=(.+)Work=(.+)/s;
}
__DATA__
Name=Paul
Phone=555-555-555
DOB=09/09/08
License=456332
Work=Doctor
.....loop through list
Basically trying to regex over mutliple lines, but regex returns nothing, works fine if it was just /Name=(.+)/
Also tried the /m modifier with /^\s+Name=(.+)^\s+Work=(.+)/
Am I understanding the /s and /m modifiers correctly?