Quote:
Originally Posted by chaley
Actually, you can't use [[ and ]] in myki's template. The problem is the "| - |" stuff inside the quotes.
|

I knew that...
Quote:
<Technical>
The template parser runs in two passes. The first, mostly controlled by the python 'format' library, extracts and parses { ... } template information. The second, mostly controlled by my code, extracts TPM functions from inside the program string using the GPM parser. The problem that arises is that the first parser sees the ':| - |' after the #series and connects it with the nearest opening brace ({), which when using [[ and ]] is the one in front of #categorieperso. The result is a mess, causing the parser to throw up its hands.
If you leave the { and } around the series ({series:| - |}) then the parser gets it right, attaching the prefix and suffix to the right variable. Unfortunately, because this parser and evaluator run before the program parser, this sub-template is evaluated and replaced with the result. If that result contains a significant character such as a quote, comma, bracket, or bar then the resulting argument for the template function will be bogus.
I have considered removing the [[ and ]] hack because the rules for successful use approach incomprehensible. 
</Technical>
|
Yeah, if you cannot get it to work consistently, I agree it shouldn't be there. Just say template() and eval() only work in GPM.