in reply to line breaks in textarea; end of line characters?
$/ and $\ seem to be what you are looking for. Look for $INPUT_RECORD_SEPARATOR and $OUTPUT_RECORD_SEPARATOR in perlvar.