Help with displaying custom content

Author Message

Lance Leger

Thursday 29 May 2003 12:00:41 am

I'm trying to list only articles that have the enable_highlight checkbox
attribute checked on a custom template.

{let $array_from_fetch = fetch( 'content', 'list', hash(parent_node_id, $node.node_id, class_filter_type, "include", class_filter_array, array(2)))}
{section name=Child loop=$array_from_fetch}
{section show=eq($Child:item.data_map.enable_highlight,"1")}
{node_view_gui view=line content_node=$Child:item}
{/section}
{/section}

This returns nothing... Any suggestions?

Thanks!

Paul Forsyth

Thursday 29 May 2003 4:24:57 am

lance,

look at the contents of your enable_highlight checkbox by trying:

{$Child:item.data_map.enable_highlight|attribute(show)}

$Child:item.data_map.enable_highlight is an object i believe so comparing it with an int like "1" will not work. However, that object has attributes which you can then test against. I can't remember off hand but it might be something like $Child:item.data_map.enable_highlight.data_int... check the result from the show command above and put in the right check.

Paul

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.