Categories > TinyButStrong general >

< (lt) and > (gt) in tbs_check ?

The forum is closed. Please use Stack Overflow for submitting new questions. Use tags: tinybutstrong , opentbs
By: deezaster
Date: 2004-06-06
Time: 22:20

< (lt) and > (gt) in tbs_check ?

i guess, that its not possbile to you "greater-than" and "lesser-than" conditions! i only can use "=" (equal) and "!=" (not-equal). and why you do not use "==" for equal like PHP?

[tbs_check.datum;block=td;if [var.TPL_today]<[result1.gamedate]]
By: Skrol29
Date: 2004-06-07
Time: 11:21

Re: < (lt) and > (gt) in tbs_check ?

Hi Deezatser,

Those two operators for conditional display are already in the wish list :) It's possible to have them, and it will probably be done in next version.

About "=" instead of "==", that was for simplicity, but it seems to disturbe some PHP developers.
By: RwD
Date: 2004-06-07
Time: 14:32

Re: < (lt) and > (gt) in tbs_check ?

alow both = and ==
By: Skrol29
Date: 2004-06-08
Time: 02:44

Re: < (lt) and > (gt) in tbs_check ?

Ok, it can be done.

But we have to replace < and > by some other characters because they make confusion with html tags.
Example :
  [var.x;if [val]>100; then 'hight']

This tag won't be seen WYSIWYG :(

Any suggestion's welcome.
By: deezaster
Date: 2004-06-08
Time: 14:07

Re: < (lt) and > (gt) in tbs_check ?

what about "gt" for > and "lt" for <
also possible "eq" for = and 'ne' for !=

gt = grater than
ge = grater or equal
lt = lesser than
le = lesser or equal
eq = equal
ne = not equal
By: Skrol29
Date: 2004-06-08
Time: 14:21

Re: < (lt) and > (gt) in tbs_check ?

Symboles are better because they are not supposed to be used in a normal string.
For example: with your syntax, the expression
'sequence' eq 'serial'
would be difficult to analyse.

what about :
+-  <==> >
+=- <==> >=
-+  <==> <
-=+ <==> <=
==  <==> ==
!=  <==> !=

or:
\  <==> >
\\ <==> >=
/  <==> <
// <==> <=
== <==> ==
!= <==> !=

By: RwD
Date: 2004-06-08
Time: 20:30

Re: < (lt) and > (gt) in tbs_check ?

I like the +- option best of the two

Might I suggest that XSLT uses &gt; and &lt; but I don't know how that affects strings  like you said though. XSLT uses them because of the < and > problem in XML...
By: Skrol29
Date: 2004-06-10
Time: 17:38

Re: < (lt) and > (gt) in tbs_check ?

"&gt;" and "&lt;" are unfortunatly not welcome inside a TBS tags because ";" is the parameter separator.
By: deezaster
Date: 2004-06-11
Time: 13:33

Re: < (lt) and > (gt) in tbs_check ?

what about:

[cond.>]
[cond.!=]
[cond.==]
:
....

examples:
[tbs_check.datum;block=td;if [var.TPL_today][cond;>][result1.gamedate]]

[tbs_check.datum;block=td;if [var.TPL_today][cond;<=][result1.gamedate]]

a little bit strange? maybe ;-)
By: Pirjo Posio
Date: 2004-06-11
Time: 19:28

Re: < (lt) and > (gt) in tbs_check ?

Everybody seems to have different opinions here:
If deezaster's system is ok, with [..] then why not have the symbols directly within [...] or (...) or {...} whichever is easiest for Skrol29:
[>=]  ==>  >=
[<=]  ==>  <=
But I thought ">" and "<" were not allowed, but could this be combined with the above suggestions of "gt" or "&gt;" etc. like this:
[gt]    ==> >
[lt]     ==> <
[gte]  ==> >=
[lte]   ==> <=