{* DO NOT EDIT THIS FILE! Use an override template instead. *}
{default attribute_base=ContentObjectAttribute}
{def $has_related_category_options=has_related_category_options($attribute.contentclassattribute_id)}
{let selected_id_array=$attribute.content}
{* Always set the .._selected_array_.. variable, this circumvents the problem when nothing is selected. *} 
<input type="hidden" name="{$attribute_base}_ezselect_selected_array_{$attribute.id}" value="">
<select id="ezcoa-{if ne( $attribute_base, 'ContentObjectAttribute' )}{$attribute_base}-{/if}{$attribute.contentclassattribute_id}_{$attribute.contentclass_attribute_identifier}" class="ezcc-{$attribute.object.content_class.identifier} ezcca-{$attribute.object.content_class.identifier}_{$attribute.contentclass_attribute_identifier}" name="{$attribute_base}_ezselect_selected_array_{$attribute.id}[]" {section show=$attribute.class_content.is_multiselect}multiple{/section} {if eq($has_related_category_options,true())}onchange='updatecategory();'{/if}>
{section var=Options loop=$attribute.class_content.options}
<option value="{$Options.item.id}">{$Options.item.name|wash( xhtml )}</option>
{/section}
</select>
{include uri="design:content/datatype/collect/parts/category.tpl"}
{/let}
{/default}
