Categories > TBS next version >

Comments for the programmer

The forum is closed. Please use Stack Overflow for submitting new questions. Use tags: tinybutstrong , opentbs
By: RwD
Date: 2004-05-17
Time: 20:54

Comments for the programmer

I would like to have 2 sets of comments in my templates...

1 is the standard <!--  -->
and the other should be for TBS and be taken out before output

[! ] or whatever for multiline (so use the TBS tags)

What do you say of this :)
By: RwD
Date: 2004-05-17
Time: 20:56

Re: Comments for the programmer

[! ] would be limited :(

perhaps use [!--  --]
so that it can encapsulate tbs tags
By: Skrol29
Date: 2004-05-17
Time: 21:35

Re: Comments for the programmer

> What do you say of this :)

I say "parameter comm".

HTML:
<!--[var.empty;comm] Bla bla bla bla-->
PHP:
$empty = '' ;
By: RwD
Date: 2004-05-18
Time: 20:33

Re: Comments for the programmer

nah, then the comment is arranged from two places. I just want something like XSL. It is possible to make comments that appear in the output, but also programmers eyes only, without any other variables it is depending on

besides, it takes more characters to make a comment...
By: Skrol29
Date: 2004-05-18
Time: 22:58

Re: Comments for the programmer

Well, you're a hard negociator.

Of course it would be cleaner to have a specific TBS tag for developper comments. But more specific tags will slow down the merge process a bit more.

Waiting for a such a solution, you can use all the same the parameter 'comm'. Here is another way without variables:

HTML:
<!--[del;comm] Bla bla bla bla-->
PHP:
$TBS->MergeField('del','');

By: Skrol29
Date: 2004-05-18
Time: 22:58

Re: Comments for the programmer

This will delete all [del] tags in one shoot.
By: RwD
Date: 2004-05-19
Time: 23:48

Re: Comments for the programmer

better :D

But needs some tweaking, I just think one shouldn't have to be able to "forget" about comments :)

Well, perhaps you will find a solution that is good, perhaps some more options at the start of the tbs file??

Like $allow_tbs_comments_in_templates = 1;