Note: This documentation is outdated, for latest, up-to date documentation please visit: https://hostbill.atlassian.net/

Email template attachment

From HostBill
Jump to: navigation, search

{attachment} can be used when creating email templates. It will allow you to include pdf invoices or normal files.

Attribute Name Type Required Description
invoice Invoice ID No Use this if you want to attach invoices to your email
file path No Path to your file that you wish to attach, use absolute paths
name string No name that will be used for attached file

Usage

Example usage in email templates:

Attach invoice

{if $invoice}
  {attachment invoice=$invoice.id}
{/if}

Use variables in file path

{attachment file="/var/acces/`$service.name`.key"}

Override attachment name

{if $invoice.gateway == 'Bank Transfer'}
  {attachment file="/var/pdfguides/banktransferguide.pdf" name="Bank Transfer Guide.pdf"}
{/if}
Personal tools