Re: Clean source code

This WebDNA talk-list message is from

2007


It keeps the original formatting.
numero = 69183
interpreted = N
texte = Dan, Are you talking about finding a good way to remove all the blank lines that are created in the HTML by every line of WebDNA code? If so, then here's what I do: When I have a block of code that will create many blank lines (like a loop or founditems) I will put "[text]garbage=" at the beginning of the block and then "end garbage[/text]" at the end of the block. This will hide all blank spaces in my final HTML. However, it also hides output, so I have to create a [finaloutput] variable inside the code block. I keep adding my results to that [finaloutput] variable and then after the loop is completed I show that [finaloutput] variable. This technique has sped up a lot of my heavily processed pages. ----------------- Matthew A Perosi Psi Prime, Inc. 323 Union Blvd Totowa, NJ 07512 Phone: 973-413-8210 Fax: 973-413-8217 Dan Strong wrote: > Hey everybody *crickets chirp*, > > Any clever ideas on how to clean up webDNA-manipulated source code, > besides adding [!][/!] all over the damn place? > My thoughts are going towards the following: > 1) [grep], but grep what? -- removing spaces inside of tags> would kill stuff and/or make the page not validate. > 2) [middle startafter=>&endbefore<] would *probably* work most of the > time, but seems server-intensive. > 3) [removeHTML] the entire final source, save what was removed, delete > everything else, then put the HTML back... same as #2... > > Lastly, when/where to put this solution? pre/post-parse script? Wrap > pages with chosen solution? > > All in all, not important, and I have done exactly zero testing, but > just wanting to see how others have dealt with this. > -Dan > > ------------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > > Web Archive of this list is at: http://webdna.smithmicro.com/ > > ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: Clean source code ( "Olin Lagon" 2007)
  2. Re: Clean source code ( "Dan Strong" 2007)
  3. Re: Clean source code ( Matthew A Perosi 2007)
  4. Clean source code ( "Dan Strong" 2007)
Dan, Are you talking about finding a good way to remove all the blank lines that are created in the HTML by every line of WebDNA code? If so, then here's what I do: When I have a block of code that will create many blank lines (like a loop or founditems) I will put "[text]garbage=" at the beginning of the block and then "end garbage[/text]" at the end of the block. This will hide all blank spaces in my final HTML. However, it also hides output, so I have to create a [finaloutput] variable inside the code block. I keep adding my results to that [finaloutput] variable and then after the loop is completed I show that [finaloutput] variable. This technique has sped up a lot of my heavily processed pages. ----------------- Matthew A Perosi Psi Prime, Inc. 323 Union Blvd Totowa, NJ 07512 Phone: 973-413-8210 Fax: 973-413-8217 Dan Strong wrote: > Hey everybody *crickets chirp*, > > Any clever ideas on how to clean up webDNA-manipulated source code, > besides adding [!][/!] all over the damn place? > My thoughts are going towards the following: > 1) [grep], but grep what? -- removing spaces inside of tags> would kill stuff and/or make the page not validate. > 2) [middle startafter=>&endbefore<] would *probably* work most of the > time, but seems server-intensive. > 3) [removehtml] the entire final source, save what was removed, delete > everything else, then put the HTML back... same as #2... > > Lastly, when/where to put this solution? pre/post-parse script? Wrap > pages with chosen solution? > > All in all, not important, and I have done exactly zero testing, but > just wanting to see how others have dealt with this. > -Dan > > ------------------------------------------------------------- > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > > Web Archive of this list is at: http://webdna.smithmicro.com/ > > ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ Matthew A Perosi

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

OPEN MARKET PATENTS SOUND ECOMMERCE ALARM (1998) possible, WebCat2.0 and checkboxes-restated (1997) encryption madness (2003) Extended [ConvertChars] (1997) WCS Newbie question (1997) [SHOWIF AND/OR] (1997) Text data with spaces in them... (1997) form data submission gets truncated (1997) Next X hits (1996) PCS Frames (1997) Setting up WebCatalog with Retail Pro data (1996) Webcatalog error, Plug-in for Webstar (1996) Help! WebCat2 bug (1997) PR: WebCatalog Affiliates Program Announced -- Share the revenue for promoting WebCatalog (2000) Color options for items (1999) READFILE command? (1998) Double Spacing in Mails from Sendmail (2002) Freeze (2003) Problem during evaluation of WebCatalog (1998) Need relative path explanation (1997)