On 11-09-2008 at 04:20:11 zou guangxian <[EMAIL PROTECTED]> wrote:

If the code is:
[CODE]
<div class="blank_bg" tal:define="book relative/book" tal:condition="php: count(book)>0"></div>
[/CODE]

will generate
[RESULT]
<?php
$ctx = $tpl->pushContext() ;
$ctx->book = phptal_path($ctx->relative, 'book', $ctx->__nothrow) ;
if (count($ctx->book)>0):  ;
endif ;
$ctx = $tpl->popContext() ;
?>
[/RESULT]

Thanks for the report.

The problem was caused by a feature that was supposed to hide <span tal:define="global var '...'"/> (perhaps it seemed like a good idea before TAL had tal:block element).

I've limited it to defines with only global keywords, so it shouldn't interfere with normal code.

The fix is in SVN:
svn co https://svn.motion-twin.com/phptal/trunk phptal

--
regards, Kornel

_______________________________________________
PHPTAL mailing list
PHPTAL@lists.motion-twin.com
http://lists.motion-twin.com/mailman/listinfo/phptal

Reply via email to