Newbie Help (WinXP)



There are 228 .html files I want to suck 4 items out of and put in a single
comma delimitted file, one line per .html file. I know how to build the
regular expressions to get the 4 items.

I know how to do this in *.NET and VB6 but I wanted to try to do it in Perl.
I downloaded perl from ActiveState.com and have successfully run a few
programs but I'm not being successful processing *.html on the command line.

I would really appreciate it if someone would reply with the WinXP command
line and the Perl program to make a single output file of [Father, Mother]
from *.html input. Sample input:

1.html

Person=George
Father=Alan
Mother=Sarah
Hobby=Cheating at dice

2.html

Person=Karen
Father=David
Mother=Mary
Hobby=Burning books

3.html

Person=Mark
Father=Sven
Mother=Helga
Hobby=Burping

Output file:

Alan, Sarah
David, Mary
Sven, Helga


Thanks!

-- Mark


.



Relevant Pages

  • Re: Help with pattern matching
    ... then print the line to an output file. ... > replica of the input file. ... In Perl, CamelBack is generall reserved for package names. ... where their meaning must be expressed in comments. ...
    (perl.beginners)
  • RE: Why wont my script terminate?
    ... No, it's not very big--might be kinda ugly to you expert Perl programmers, ... to this list (DBI version 1.14 written by Tim Bunce for MsWin32). ... Here's my script: ... 'TEST_' to output file names.) ...
    (perl.dbi.users)
  • glob in specific directory
    ... I am writing a DTS package task in perl but am having trouble with the ... script from a specific directory, it's run by the sql server. ... is a user supplied string ... Nothing is getting written to me output file, ...
    (comp.lang.perl.misc)
  • Re: Need File I/O Help....
    ... >I need help with file manipulation in Perl. ... > in the file to an OUTPUT FILE (BY APPENDING). ... > Perl but know that ir is great with this sort of activity. ...
    (comp.lang.perl.misc)
  • Re: Question regarding splitting files
    ... > I have a question about how i can split files. ... Depending on the size of the files you may need a Perl enabled with ... perl -V should tell you if your Perl is setup ... > print line of the content to $output file ...
    (perl.beginners)