1. Home
  2. Docs
  3. PDF Invoice Generator
  4. Setup


Template Editor

Sample HTML Value

Switch to source code mode by clicking the Source button and save the below HTML

<p><strong style="font-size: 11px;">{store_name}</strong><br />
<span style="font-size: 11px;">{store_address}<br />
<strong>Telephone:</strong>&nbsp;{store_telephone}<br />
<strong>Email:</strong>&nbsp;{store_email}<br />

<p><strong>Total Amount : {total}</strong></p>

<table border="0" cellpadding="1" cellspacing="1" width="100%">
<th scope="col"><strong><span style="font-size: 11px;">Order ID : {order_id}</span></strong></th>
<th scope="col"><strong><span style="font-size: 11px;">Billing Address</span></strong></th>
<th scope="col"><strong><span style="font-size: 11px;">Shipping Address</span></strong></th>
<p><span style="font-size: 10px;"><strong>Invoice Number:</strong>&nbsp;{invoice_no}</span><br />
<span style="font-size: 10px;"><strong>Purchase Date:</strong>&nbsp;{date_added}</span><br />
<span style="font-size: 10px;"><strong>Payment Method:</strong>&nbsp;{payment_method}</span><br />
<span style="font-size: 10px;"><strong>Shipping Method:</strong>&nbsp;{shipping_method}</span></p>
<td><span style="font-size: 11px;">{payment_address}</span></td>
<td><span style="font-size: 11px;">{shipping_address}</span></td>


<p style="text-align: center;"><span style="font-size: 9px;">This is a computer generated invoice. No signature required.&nbsp;</span></p>

Cart Template file

The shortcode / variable {cart_items} uses this template file to insert the table format of the invoice items and totals.

You can also create/design your own template file and keep the template file under catalog/view/theme/default/template/pdfinvoice/

By default these templates are set in English language. If your website is single language and is not English then you edit language terms in these files. If you are using multi-language site, you may need to replicate the file and edit language terms. For example you are using cartitems.tpl for English, then you can duplicate this file cartitems.tpl and name it as cartiterms_fr.tpl and edit the vocabulary in the file. Then in setting page select the appropriate file in English setup and for French setup.

PDF Header Title

This is an optional field. You can enter any Text, for example store name, and it will appear at the top of all pages in PDF invoice

PDF Header Text

Similar to PDF header title, this is also an optional field. You can provide any text

PDF Footer Content

The data provided in this field will appear in PDF bottom of all pages.

PDF Footer Content Position

You can adjust position the content of the footer (w.r.t PDF Footer Content).

Sample Value can be 280.

  • If you want to adjust the footer to position a little high, then decrease this value.
  • If you want to adjust the footer to position a little below, then increase this value.

Secured Folder Name

Parent folder for all the PDF invoice saved in your server is system/storage/invoice/ . Within this location a folder will be created by the name you mentioned in this field to keep all your customer’s invoice safe. Keep the name hard to guess by anyone. Do not use special characters or spaces for this value.

Auto Create Invoice Number

If enabled, invoice number will be automatically created when PDF invoice is generated

Required Fields

Make sure you do not keep any of these fields empty, or else it will end up in error while PDF invoice generation

  • Template Editor
  • Cart Template file
  • PDF Footer Content Position
  • Filename Prefix
  • PDF Orientation
  • Enable Header
  • Secured Folder Name
  • Order Status
  • Auto Create Invoice Number
  • Invoice Product Image Dimension
  • Enable Barcode/QR code
Was this article helpful to you? Yes No