Make sure each section is separated by a new line, including the last
section. If there is no new line at the end of the file, the last record
will be omitted.
The following puts each field in %data with the field name being the key and
the field value as the key's value, and it splits each line
multiline data
Hello everyone,
I have several sections of data that look like this:
Title: DESIGN JOURNAL (COVER)
Purpose: Product Spotlight
Penetration: National
Role: Media Relations, Content Support
Results: Elevated Publicity and Brand Awareness
Credits: Evolutif Senior Management Team
Award
On Thu, 21 Oct 2004 14:55:28 +0800, Bee [EMAIL PROTECTED] wrote:
use strict;
open F, sourcefile.txt;
local $/ = \n\n;
my @sections = F;
close F;
print Section $_ :\n $sections[$_]\n\n for @sections;
What are you doing to poor Kevin?
If you meant:
print Section $_:\n
print Section $_ :\n $sections[$_]\n\n for @sections;
What are you doing to poor Kevin?
If you meant:
print Section $_:\n $sections[$_]\n\n for 0..$#sections;
then I'll forgive you :-)
Oops. What a mistake !! Thousands sorry...
( I can't forgive myself ) ~^.^~
Bee
--
Hello everyone,
I have several sections of data that look like this:
Title: DESIGN JOURNAL (COVER)
Purpose: Product Spotlight
Penetration: National
Role: Media Relations, Content Support
Results: Elevated Publicity and Brand Awareness
Credits: Evolutif Senior Management Team
Award: 2001 Award
On Wed, 20 Oct 2004 22:27:20 -0400, Kevin Old [EMAIL PROTECTED] wrote:
Hello everyone,
I have several sections of data that look like this:
Title: DESIGN JOURNAL (COVER)
Purpose: Product Spotlight
Penetration: National
Role: Media Relations, Content Support
Results: Elevated Publicity