Of course I didn't mention the need to read the file first...I thought that was a 'given'....sheesh.
my(@lines) = <MYINPUTFILE>;
@lines = sort(@lines);
foreach $line (@lines)
open (LOG, '+>comments.html');"
That's for all you people who need their hand held.