Print Form Template Development for 1C-Bitrix
A manager clicks "Print Order" in the Bitrix admin panel. A page opens with order data — no logo, no company details, system field names instead of readable labels. This needs to go to the client or be taken to the warehouse. It prints on A4, gets clipped at the edges, and has no header. This happens on the majority of Bitrix installations with default settings.
Print Form Template Development for 1C-Bitrix
Where Print Forms Live in Bitrix
Bitrix uses the term "print forms" to refer to several distinct entities that are often confused:
Order print view — generated via the bitrix:sale.order.detail component or directly from the admin order section. The print template is located in the sale module files.
Sale module print forms — configured under Store → Print Forms. Bitrix supports several types: delivery note, invoice, receipt. Each form is a PHP template with access to the order object.
Custom print forms — implemented via event handlers or separate PHP pages with CSS @media print.
Developing a Print Form
A print form is an HTML page optimized for printing using CSS @media print:
@media print {
body { margin: 0; font-size: 11pt; }
.no-print { display: none; }
@page { size: A4; margin: 15mm 10mm; }
}
Structure of a typical order print form:
- Header: company logo, details, date, document number
- Recipient data: full name, delivery address, contact
- Items table: name, SKU, quantity, price, total
- Totals: item cost, delivery, discount, grand total
- Signatures and stamp: signature field, stamp area (if required)
Data is retrieved via the sale module API: CSaleOrder::GetByID(), CSaleBasket::GetList(), CSaleDelivery::GetByID(), requisites via CSaleOrderPropsValue::GetList().
Admin Panel Integration
To add a "Print" button to the order card, use the OnBuildGlobalMenu event handler or a custom page in /local/admin/. The page receives ORDER_ID from the GET parameter, loads the order data, renders the HTML, and calls window.print() on open.
A more convenient approach is PDF generation via the mPDF or TCPDF libraries, included as Composer packages. The user clicks "Download PDF" and receives a ready document without dependency on a browser print driver.
Case Study: Warehouse Delivery Note
A wholesale company with orders assembled in a warehouse. A required A4 delivery note: items table (SKU, name, unit of measure, quantity, storage cell), order barcode, and warehouse keeper signature.
We developed a dedicated page at /local/admin/sale_print_warehouse.php. Data: items from CSaleBasket, storage cell from a custom product property. Barcode — picqer/php-barcode-generator library via Composer, rendered as SVG. Printing — via browser with CSS @media print. A "Warehouse Note" button was added to the order list via OnBuildGlobalMenu. The work took 3 days.
Timeline
| Task | Timeline |
|---|---|
| Customizing an existing print form (styles, company details) | 4–8 hours |
| Developing a new print form (HTML + CSS print) | 1–2 days |
| Print form with PDF generation and an admin button | 2–4 days |

