1. What this module does

The module adds a Download PDF sheet button to the product page. One click gives the customer a clean, printable PDF of the product: name, images, price, availability, features, combinations and more — in the customer's language and currency, for the combination they selected. You decide in the configuration what the PDF contains and how it looks. From the product page in the Back Office you can also generate the same sheet for a customer, in any language, currency and customer group.

Works with PrestaShop 1.7.8, 8.x and 9.x (PHP 7.2.5 or newer), with the Classic and Hummingbird themes and with multistore.

2. Installation

  1. Download the module from My account → Order history at addonspresta.com.
  2. In your Back Office, open Modules → Module Manager and click Upload a module.
  3. Drop the ap_productpdf_v1.0.0.zip file and wait for the confirmation.
  4. Click Configure on the module card.

After installation the button already appears on product pages with the default settings.

3. How it works

The PDF is created at the moment the customer clicks the button, from the current product data. Prices come from PrestaShop's own price calculation for that customer: specific prices, catalog price rules and group discounts are included, in the currency of the visitor and with the tax of their address. When the customer changes the combination on the product page, the button follows: the PDF shows the selected combination, its images, reference and price.

A PDF is never created for a product that your shop does not show to this visitor: inactive products, products of another shop, products hidden everywhere or in categories closed to the visitor's group. The same applies when you hide the button for a group, a category or a product: the PDF link stops working too.

To save server resources, a PDF made for a visitor who is not logged in is kept for 60 minutes (you can change this); logged-in customers, who may have their own prices, always get a fresh PDF. Saving the settings or editing the product creates a new one at once. The PDF is drawn by the TCPDF library built into PrestaShop. The module does not change PrestaShop tables and does not connect to addonspresta.com or any other server; images and links of the product description are left out of the PDF.

Prices in catalog mode. The PDF shows prices as you set them in the module, also in catalog mode, for customer groups that do not see prices and for products with hidden prices. If your shop hides prices on purpose (for example for B2B customers before they log in), switch on Hide prices when the shop hides them.

4. Features and settings

Open Modules → Module Manager → Product PDF Sheet → Configure. The Help box at the top links to this manual and to the module page at addonspresta.com, in the language of your Back Office.

Button on the product page

  • Enable the PDF sheet — switched off, the button disappears and the PDF links stop working. The Back Office panel keeps working.
  • Button position — below the add to cart button, next to it, or in the reassurance block. The exact place depends on your theme.
  • Button label — the text of the button in every language, up to 64 characters. Empty means the default label.
  • Open the PDF — download the file, or open it in a new browser tab.
  • Customer groups — only customers of the ticked groups see the button. Visitors who are not logged in belong to the Visitor group.
  • Logged-in customers only — hides the button from visitors.
  • Hide in categories — products in any ticked category get no button.
  • Hide for products — product IDs separated by commas, up to 500.

Content of the PDF

Each switch adds one part of the PDF: product name, reference, EAN-13 / UPC / ISBN / MPN codes, brand, default category, short description, description, price, regular price and discount, unit price, availability and delivery time, quantity in stock, attributes of the selected combination, table of all combinations, features, weight and dimensions, names of the attached documents, link to the product page, QR code and EAN-13 barcode.

  • Images — no images, the cover image only, the cover image with thumbnails, or all images in a grid. The images of the selected combination come first. Maximum number of images limits them (1 to 12) and Image size chooses one of your product image types: larger images look sharper and make bigger files.
  • Price — as the customer group displays prices (tax included or excluded), tax included, tax excluded, both, or no prices.
  • Hide prices when the shop hides them — see "How it works".
  • Quantity in stock — printed only when stock management is on in your shop.
  • Table of all combinations — one row per combination with the columns you tick (reference, EAN-13, price, quantity, availability), up to the maximum you set (1 to 500).
  • EAN-13 barcode — printed only when the product or the combination has a valid EAN-13 code.
  • Description — headings, lists, bold text and tables are kept.

Look

  • Paper size — A4 or Letter.
  • Accent colour — a hex colour such as #333333 for the line under the title, the section headings and the table header.
  • Shop logo in the header — the invoice logo, or the shop logo when there is none.
  • Shop details in the header — name, address, phone and e-mail from Shop Parameters → Contact → Stores.
  • Page numbers and Generation date in the footer.

Texts

Three texts for each language: above the product (up to 300 characters), a note below the product (up to 1000) and the footer (up to 300). They are plain text; {shop_name}, {shop_url}, {date}, {product_name} and {reference} are replaced with the values of the shop and the product. The default note reads "Prices and availability valid on {date}. This document is not an offer."

Cache

Keep generated PDFs for (minutes) — from 0 to 10080 (one week); 0 creates every PDF again. Clear the PDF cache removes the stored files at once, for example after you changed prices with a catalog price rule. Expired files are deleted automatically. The configuration page warns you when the cache is off, and when your shop hides prices while the PDF shows them.

PDF in the Back Office

On the product page in the Back Office, open the Modules tab and choose Product PDF Sheet. Select the language, the currency, the customer group whose prices the sheet shows and the combination, then click Generate PDF. The sheet opens in a new tab; send it to your customer like any file. The button settings (groups, categories, products, on / off) do not apply here. Only employees whose profile has the View permission of the module and can open Catalog → Products see the panel; grant the module permission in Advanced Parameters → Team → Permissions.

5. Multistore

Settings are saved for the shop or shop group selected in the Back Office header. Select All shops to set the same values everywhere, or a single shop to give it its own button, content and texts. In the All shops or group context only an employee who manages every shop of it can save. Each shop's PDF uses its own products, prices, stock, images, logo and contact details. In the Back Office, the PDF is created for the shop selected in the header, or for the product's default shop in the All shops context. One licence covers every shop of the installation.

6. Uninstall

Module Manager → Product PDF Sheet → Uninstall removes the module's settings, its hidden Back Office page and the stored PDF files. To keep the settings, use Disable instead.

7. FAQ and troubleshooting

The button does not appear. Check that Enable the PDF sheet is on, that the visitor's group is ticked in Customer groups, that the product and its categories are not hidden, and that your theme prints the chosen position. Try Below the add to cart button, then clear the cache in Advanced Parameters → Performance.

The PDF shows an old price. A price changed by a dated specific price or a catalog price rule appears when the stored PDF expires. Click Clear the PDF cache or lower the cache time.

There is no QR code or barcode in the PDF. The server needs the PHP extension GD or Imagick; the configuration page warns you when both are missing. The barcode also needs a valid EAN-13 code.

An image or a video from my description is missing. This is on purpose: the PDF contains only the text of the description, its formatting and tables.

Can I change the layout of the PDF? Yes. Copy views/templates/pdf/sheet.tpl (and header.tpl / footer.tpl) to themes/<your-theme>/modules/ap_productpdf/views/templates/pdf/ and edit the copies. A developer can also add data with the actionApProductpdfData hook described in README.md.

A text is still in English in my Polish or French shop. Fill in the button label and the texts for that language in the module configuration. Other wording can be changed in International → Translations → Installed module translations.

8. Updates and support

Updates are free for life: download new versions from My account → Order history at addonspresta.com and upload them like a new module. Your settings are kept.

Support is included for 12 months from your order: write to mail@addonspresta.com or use the contact form at addonspresta.com (Monday to Friday, 10:00–16:00 CET; we usually answer within 2 business days). Please include your PrestaShop version, the module version and the steps that lead to the problem.

Back to User manuals

Loading...
Back to top