Re: Removing blank lines
- From: emailgrant@xxxxxxxxx (Grant)
- Date: Mon, 12 Mar 2007 13:37:02 -0700
>> $val =~ s/^\s*\n//mg;
> I'm not having any luck there either. I'm not sure what is actually
> creating the blank lines. It could be spaces, tabs, or some other
> blank line creator.
The \s marker will match all of those. Can you show us your code please?
Don't forget that your function is returning the modified text and you have
to assign it to something - it won't change the contents of the string you
pass as a parameter written that way.
In this instance I have two blank lines in the delivered HTML between
htmltag1 and htmltag2:
If I use the filter like this:
I get only one blank line, so it is an improvement. Should it be
possible to remove the blank lines entirely?