{* +--------------------------------------------------------------------+ | CiviCRM version 4.7 | +--------------------------------------------------------------------+ | Copyright CiviCRM LLC (c) 2004-2017 | +--------------------------------------------------------------------+ | 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 | +--------------------------------------------------------------------+ *} {if $form.attachFile_1 OR $currentAttachmentInfo} {if $action EQ 4 AND $currentAttachmentInfo} {* For View action we exclude the form fields and just show any current attachments. *} {foreach from=$currentAttachmentInfo key=attKey item=attVal}
{$attVal.cleanName} {if $attVal.description} - {$attVal.description}{/if} {if !empty($attVal.tag)}
{ts}Tags{/ts}: {$attVal.tag}
{/if}
{/foreach} {elseif $action NEQ 4} {if $context EQ 'pcpCampaign'} {capture assign=attachTitle}{ts}Include a Picture or an Image{/ts}{/capture} {else} {capture assign=attachTitle}{ts}Attachment(s){/ts}{/capture} {/if} {if !$noexpand}
{$attachTitle}
{/if}
{if $form.attachFile_1} {if $context EQ 'pcpCampaign'}
{ts}You can upload a picture or image to include on your page. Your file should be in .jpg, .gif, or .png format. Recommended image size is 250 x 250 pixels. Images over 360 pixels wide will be automatically resized to fit.{/ts}
{/if} {if $form.tag_1.html} {/if} {if $tagsetInfo.file} {include file="CRM/common/Tagset.tpl" tagsetType='file' tableLayout=true tagsetElementName="file_taglist_1"} {/if} {section name=attachLoop start=2 loop=$numAttachments+1} {assign var=index value=$smarty.section.attachLoop.index} {assign var=attachName value="attachFile_"|cat:$index} {assign var=attachDesc value="attachDesc_"|cat:$index} {assign var=tagElement value="tag_"|cat:$index} {if $tagsetInfo.file} {include file="CRM/common/Tagset.tpl" tagsetType='file' tableLayout=true tagsetElementName="file_taglist_$index"} {/if} {/section} {/if} {if $currentAttachmentInfo} {/if}
{$form.attachFile_1.label} {$form.attachFile_1.html} {$form.attachDesc_1.html}
{ts}Browse to the file you want to upload.{/ts}{if $maxAttachments GT 1} {ts 1=$maxAttachments}You can have a maximum of %1 attachment(s).{/ts}{/if} {ts 1=$config->maxFileSize}Each file must be less than %1M in size. You can also add a short description.{/ts}
{$form.tag_1.label}
{$form.tag_1.html}
{$form.attachFile_1.label} {$form.$attachName.html} {$form.$attachDesc.html}
{$form.$tagElement.label}
{$form.$tagElement.html}
{ts}Current Attachment(s){/ts} {foreach from=$currentAttachmentInfo key=attKey item=attVal}
{$attVal.cleanName} {if $attVal.description} - {$attVal.description}{/if} {if $attVal.deleteURLArgs} {/if} {if !empty($attVal.tag)}
{ts}Tags{/ts}: {$attVal.tag}
{/if}
{/foreach}
  {$form.is_delete_attachment.html} {$form.is_delete_attachment.label}
{literal} {/literal} {/if} {* edit/add if*} {if $currentAttachmentInfo} {include file="CRM/Form/attachmentjs.tpl"} {/if} {/if} {* top level if *}