Remove Blank Lines in Dreamweaver

by | Oct 3, 2013 | Dreamweaver | 0 comments

I was recently working on a website in Dreamweaver and had both PHP and CSS files with loads of blank lines of code, which needed to be deleted in order to make the files smaller.

So instead of doing it manually one at a time… which would have taken ages. I used a nice little tip in Dreamweaver.

1. Open the document you need to change.
2. Click CMD + F (Mac) or CTRL + F (PC).
3. In the Find and Replace window change the following:

Find in: to Current document
Search: to Source code
Find: input [\r\n]{2,}
Replace: input \n
Options: tick Use regular expression

4. Finally select Replace All.

By Anthony Bear
Anthony Bear is an entrepreneur, musician, writer and the ultimate creative nerd. He is the founder of Humanity Media Inc., Bear Blend LLC, and Herbal Intelligence. And when he has spare time, he likes to write music and hang out with his family in San Diego.


Submit a Comment

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.