Welcome to WebmasterWorld Guest from 54.163.84.187

Forum Moderators: incrediBILL

Removing whitespaces

   
4:12 pm on Sep 4, 2004 (gmt 0)

10+ Year Member



Hello,
does anyone know if it is possible to remove all white spaces in my html code using DW 7.
For some reason when a client sends me their latest page updates it has tons of needless whitespace and the page has 600 lines of html which should normally be about 350 without all the spaces.
Or is their another program that can do this safely.

thanks
cf

3:00 am on Sep 7, 2004 (gmt 0)

10+ Year Member



I've had a similar problem. In my case I wanted to replace period single whitepace (ie. ". ") with period double white space (ie. ".  ").

DW seems to ignore the whitespace completely in the "from" string (eg. changing 1.00 to "1.  00"!)

I don't know if DW supports regex - but I realised that it was just as easy for me to do the replace with Notepad before I started off on that path.

If the files are too big maybe try Wordpad or Word (or whatever editor you want really).

Word's pretty good at that sort of stuff - you can replace paragraph marks etc too (look at special characters in the help). So, for example replacing " ^p" with "^p" replaces the whitespace at the end of each line only. Run it repeatedly and all trailing whitespace is gone (but then I think they may have a macro do that - you get my drift anyway).

3:38 am on Sep 7, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Try:
Commands > Apply source formatting
 

Featured Threads

Hot Threads This Week

Hot Threads This Month