{* +--------------------------------------------------------------------+ | CiviCRM version 4.4 | +--------------------------------------------------------------------+ | Copyright CiviCRM LLC (c) 2004-2013 | +--------------------------------------------------------------------+ | This file is a part of CiviCRM. | | | | CiviCRM is free software; you can copy, modify, and distribute it | | under the terms of the GNU Affero General Public License | | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. | | | | CiviCRM is distributed in the hope that it will be useful, but | | WITHOUT ANY WARRANTY; without even the implied warranty of | | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | | See the GNU Affero General Public License for more details. | | | | You should have received a copy of the GNU Affero General Public | | License and the CiviCRM Licensing Exception along | | with this program; if not, contact CiviCRM LLC | | at info[AT]civicrm[DOT]org. If you have questions about the | | GNU Affero General Public License or the licensing of CiviCRM, | | see the CiviCRM license FAQ at http://civicrm.org/licensing | +--------------------------------------------------------------------+ *} {assign var="element_name" value=$element.element_name} {if $element.help_pre}   {$element.help_pre} {/if} {if $element.options_per_line != 0 } {$form.$element_name.label}{if $element.help_post}{help id=$element.id file="CRM/Custom/Form/CustomField.hlp" title=$element.label}{/if} {assign var="count" value="1"} {* sort by fails for option per line. Added a variable to iterate through the element array*} {assign var="index" value="1"} {foreach name=outer key=key item=item from=$form.$element_name} {if $index < 10} {assign var="index" value=`$index+1`} {else} {if $count == $element.options_per_line} {assign var="count" value="1"} {else} {assign var="count" value=`$count+1`} {/if} {/if} {/foreach} {if $element.html_type eq 'Radio' and $element.is_view eq 0} {/if}
{$form.$element_name.$key.html}
({ts}clear{/ts})
{else} {$form.$element_name.label}{if $element.help_post}{help id=$element.id file="CRM/Custom/Form/CustomField.hlp" title=$element.label}{/if} {if $element.data_type neq 'Date' OR ($element.data_type eq 'Date' AND $element.is_view eq 1)} {$form.$element_name.html}  {elseif $element.skip_calendar NEQ true} {include file="CRM/common/jcalendar.tpl" elementName=$element_name} {/if} {if $element.html_type eq 'Radio' and $element.is_view eq 0} ({ts}clear{/ts}) {elseif $element.data_type eq 'File'} {if $element.element_value.data}

 {ts}Attached File{/ts}:   {if $element.element_value.displayURL} {else} {$element.element_value.fileName} {/if} {if $element.element_value.deleteURL} {/if}
{/if} {elseif $element.html_type eq 'Autocomplete-Select'} {if $element.data_type eq 'ContactReference'} {include file="CRM/Custom/Form/ContactReference.tpl"} {else} {include file="CRM/Custom/Form/AutoComplete.tpl"} {/if} {/if} {/if}