Drupal is a registered trademark of Dries Buytaert

print_this_page

58 sites Security covered
View on drupal.org

This module provides a customisable print button block allows users to print the current page. The button is accessible and can be placed in any region or entity display via the block layout or display management. The module includes options to customise the link text, show/hide the print icon, and exclude specific page elements from printing.

Features

  • Accessible print button with proper ARIA attributes
  • Visual states for hover, focus, and active interactions
  • Hidden when JavaScript is disabled to avoid confusion
  • Google Analytics integration via dataLayer events
  • Customisable link text
  • Optional print icon display (SVG-based)
  • Configurable element exclusion from printing
  • Can be placed in any block region or added to entity display

Post-Installation

Block Configuration
When placing the Print This Page block, you can configure:

  • Link Text: Customise the text displayed for the print link (default: "Print this page")
  • Show print icon: Toggle display of the print icon next to the text
  • Elements to exclude from printing: Comma-separated list of CSS selectors to hide when printing

Field Formatter Settings
When using the Print This Page formatter on a field, you can configure:

  • Link Text: Customise the text displayed for the print link
  • Show print icon: Toggle display of the print icon next to the text
  • Elements to exclude from printing: Comma-separated list of CSS selectors to hide when printing

Exclude Elements from Printing
You can specify CSS selectors (IDs, classes, or element names) that should be hidden when printing. Common examples:

  • `header, footer, aside, nav` - Hide structural elements
  • `.menu, .breadcrumb` - Hide navigation elements
  • `form, iframe` - Hide interactive elements
  • `#sidebar, .comments` - Hide specific sections

Similar projects

Although there are other print modules for Drupal, this one stands out because of its intuitive interface, wide range of configuration options, and removal of elements on print.
Print js button, Entity Print

Activity

Total releases
1
First release
Jun 2025
Latest release
8 months ago
Release cadence
Stability
100% stable

Releases

Version Type Release date
1.0.1 Stable Jun 8, 2025