On 2 Oct 2010, at 07:15, romtek wrote:

> Hi,
> 
> I sometimes need to use multiple values for the class attribute but can't 
> seem to find a way to do this in PHPTAL if those values are to be determined 
> at run-time. For example,
> 
> <tr tal:attributes="class php:item.isParent() ? 'parent' : null">...</tr>
> I also need to set an additional class value, say:
> "class php:item.is_inactive ? 'inactive' : null"
> 
> Would somebody please suggest a way to do this?

If you don't mind getting class=" " sometimes (harmless in HTML), then you can 
simply use:

<tr class="${php:…} ${php:…}">

-- 
regards, Kornel


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

Reply via email to