Thursday 21 September 2006 6:09:21 am - 3 replies
laurent le cadet
Thursday 21 September 2006 6:38:02 am
as is an array, I also tryed this :
{set-block scope=root variable=email_receiver} {let selected_id_array=$node.object.data_map.zone_geographique.attribute.content} {section var=Options loop=$node.object.data_map.zone_geographique.attribute.class_content.options} {section show=$selected_id_array|contains( $Options.item.id )} {switch match=$Options.item.id} {case match=0}first@domain.com{/case} {case match=1}second@domain.com{/case} {case match=2}third@domain.com{/case} {case match=3}fourth@domain.com{/case} {case}{/case} {/switch} {/section} {/section} {/let} {/set-block}
Till no result :(
Thursday 21 September 2006 7:17:25 am
based on ezenhancedselection.tpl :
{let selected_id_array=$node.object.data_map.zone_geographique.attribute.content selected_array=array()} {section name=Option loop=$node.object.data_map.zone_geographique.attribute.class_content.options} {section-exclude match=$selected_id_array|contains($Option:item.identifier)|not} {$Option:item.name|wash(xhtml)}{delimiter}{cond($node.object.data_map.zone_geographique.attribute.class_content.delimiter|ne(""),$node.object.data_map.zone_geographique.attribute.class_content.delimiter,", ")}{/delimiter} {/section} {/let}
But I always have the first item of the list even if it's another one that is choiced.
:(((
Thursday 21 September 2006 8:06:05 am
pfuuuu...
{let email=$collection.attributes[9]} {switch match=$email.data_text|wash(xhtml)} {case match="Europe"}{set-block scope=root variable=email_receiver}europe@domain.com{/set-block}{/case} {case match="USA"}{set-block scope=root variable=email_receiver}usa@domain.com{/set-block}{/case} {case match="Asia"}{set-block scope=root variable=email_receiver}asia@domain.com{/set-block}{/case} {case match="Africa"}{set-block scope=root variable=email_receiver}africa@domain.com{/set-block}{/case} {/switch} {/let}
It wasn't so hard Laurent !
Hope this help.
You must be logged in to post messages in this topic!