hi all

I have defined a function in page like such code:
<table py:def="display_pages(pages)">
....
</table>

And I can call this function by ${}:
${display_pages(space.root_pages)}

But I want to send different parameter to this function by different condition.
So I write the embedded python code:
<?python
    if not current_page:
        display_pages(space.root_pages)
    elif current_page:
        display_pages(current_page.sub_pages)
?>

But it is not worked, there is not any thing showed in page.

-- 
with kind regards

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
kid-template-discuss mailing list
kid-template-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kid-template-discuss

Reply via email to