Thursday 06 January 2005 11:14:37 am
Hi Nico! Only certain types of dataypes can be filtered in in a fetch using attribute-filter. See http://ez.no/ez_publish/documentation/reference/data_fetching/content/list I really don't know if this will work, but if the attribute is of datatype ezstring (which it's probably not) you could try
'attribute_filter', array( array( 'your_class/aktuelles',
'>',
'0' ) )
It's good practice to also filter on class when filtering on attribute. If this is not working, my only solution would be to fetch all nodes and make a counter in the loop and test the aktuelles-attribute for content.
{let counter=0}
{section loop=$nodes}
{section show=and($counter|lt(5), count_chars(trim($:item.data_map.aktuelles.data_text))|gt(0))}
{set counter=$counter+1}
<a href={concat("/content/view/full/",$:item.node_id)|ezurl}>{$:item.data_map.aktuelles.data_text}</a><br /><br />
{/section}
{/section}
{/let}
This is a ugly hack and will continue to iterate the $node-loop even when 5 items has been written. Hope someone comes up with a better solution. Roy
|