Developer forum

Forum » Feature requests » Comments in templates

Comments in templates

Lars Larsen
Reply

Hi,

It would be great if it was possible to insert comments in templates, and these comments was not outputted to the client. How about introducing this new tag couple:

 

<!--@CommentStart-->
This is my comment that will not be outputted to the client :-)
<!--@CommentEnd-->

When DW parses the tags is should remove everything: starttag, comment and endtag. It would be nice if no empty lines were left from the comments (when using the Snippets tag DW leaves at least one empty line for each snippet in the page).


Replies

 
Nicolai Høeg Pedersen
Reply

Hi Lars

 

You can actually use snippets. Will look into the issue with the additional line break.

 

 

 

<!--@SnippetStart(MyComment)-->

All this will be removed

<!--@SnippetEnd(MyComment)-->
 
Lars Larsen
Reply

Year you'r right about using the snippets tags. But think a couple of comment tags would be more clean. Anyway it would be great if the fixed the line break issue, thanks :-)