You are here

function printable_pdf_theme in Printer and PDF versions for Drupal 8+ 8

Same name and namespace in other branches
  1. 2.x modules/printable_pdf/printable_pdf.module \printable_pdf_theme()

Implements hook_theme().

File

modules/printable_pdf/printable_pdf.module, line 11
Provides a printable format for generating PDFs.

Code

function printable_pdf_theme() {
  $module_path = drupal_get_path('module', 'printable_pdf');
  return [
    'printable_pdf_footer' => [
      'template' => 'printable-footer',
      'pattern' => 'printable_footer__',
      'variables' => [],
      'path' => $module_path . '/templates',
    ],
    'printable_pdf_header' => [
      'template' => 'printable-header',
      'pattern' => 'printable_header__',
      'variables' => [],
      'path' => $module_path . '/templates',
    ],
  ];
}