You are here

function google_cse_theme in Google Custom Search Engine 8.3

Same name and namespace in other branches
  1. 8 google_cse.module \google_cse_theme()
  2. 8.2 google_cse.module \google_cse_theme()
  3. 6 google_cse.module \google_cse_theme()
  4. 7.3 google_cse.module \google_cse_theme()
  5. 7 google_cse.module \google_cse_theme()
  6. 7.2 google_cse.module \google_cse_theme()

Implements hook_theme().

File

./google_cse.module, line 60
Display a Google Custom Search Engine (CSE) on your site.

Code

function google_cse_theme($existing, $type, $theme, $path) {
  return [
    'google_cse_results' => [
      'variables' => [
        'form' => FALSE,
        'path' => $path,
      ],
      'file' => 'google_cse.theme.inc',
      'template' => 'google_cse_results',
    ],
    // @TODO confirm the placement of template file.
    // @see https://www.drupal.org/node/2853472
    'google_cse_adv_results' => [
      'variables' => [
        'form' => FALSE,
        'path' => $path,
      ],
      'file' => 'google_cse.theme.inc',
      'template' => 'google_cse_adv/templates/google_cse_adv_results',
    ],
  ];
}