Preview a template
The preview beside the editor renders your template as you type, so you can check a change before you save it. Knowing what it's filling the template with is the difference between trusting it and being misled by it.
Before you begin
- Open a template in Settings → PDF Templates. The preview is the right-hand half of the workspace.
- The preview has two modes — Interactive and PDF. Interactive is the fast, clickable one; PDF is the real document. See the template editor reference for how each behaves.
Preview against a real order
- Find the Sample order box in the preview toolbar. Left empty, the preview fills the template with realistic built-in sample data.
- Click it. Your twenty most recent orders are listed, each showing the order number and the store. Type to search for a different one.
- Choose an order. A packing slip preview is rebuilt from that order's actual customer, address and products.
This is the fastest way to check a change against a specific case — an international address, a very long product name, an order with many lines.
Clear the box to go back to sample data.
Know what the built-in sample can't show you
Every address in the sample — customer, billing, store, supplier and warehouse — is in the United States, and the sample order carries no discount.
So a block written to appear only for New Zealand, Australia, or any non-US destination — or only when a discount exists — correctly shows nothing in the preview even when your template is perfectly right. The preview isn't broken; the sample simply doesn't meet the condition.
To check one of those blocks:
- On a packing slip, pick a real order going to that destination in the Sample order box.
- On any other document type, temporarily change the code to
US(or make the wording unconditional) to confirm the block itself renders, then change it back. Or generate the document from a real record.
See where a field lands on the page
With the preview on Interactive, move your cursor over a placeholder in the code. The matching text is outlined in the preview with a dotted highlight.
It's the quickest way to work out which part of the layout a field controls, and to trace which line produced which piece of the page.
This only works in Interactive mode — the PDF tab is a flat document with nothing to highlight.
Resize an image by dragging it
In Interactive mode, drag an image in the preview to resize it. The editor writes the new dimensions back into the template for you, so you don't have to find the right line yourself.
Two things to expect:
- If the editor can't work out which part of the template produced that image, it says Couldn't find the source to resize — try editing manually and leaves the template untouched.
- When the same image appears more than once — inside the line-items block, for example — every copy shares a single size.
Next steps
- Add logos, images & footer banners — get the artwork in before you size it.
- Edit a template — the authoring loop the preview is checking.
- Page setup & CSS support — why the PDF can differ from the interactive view.