Copy link to clipboard
Copied
Anyone got a tried and tested find and replace regex for removing empty lines in DW 2018 please?
This seems to find empty lines:
^(?:[\t ]*(?:\r?\n|\r))+
But if I leave the replace field empty and click replace all - nothing happens.
the expression that you had enter so far is working good at least in many text editor but in dreamweaver
as you point at the [\r\n]{2,} replaced by \n can do the job, but will avoid lines starting by a TAB char... (it often happen in code text)... perhaps adding a \t starting the square bracket will help to catch them
Copy link to clipboard
Copied
This appears to work:
https://www.brmecham.com/how-to-remove-blank-lines-in-dreamweaver/
Copy link to clipboard
Copied
the expression that you had enter so far is working good at least in many text editor but in dreamweaver
as you point at the [\r\n]{2,} replaced by \n can do the job, but will avoid lines starting by a TAB char... (it often happen in code text)... perhaps adding a \t starting the square bracket will help to catch them