You are here

video_embed_html5.module in Video Embed HTML5 8

File

video_embed_html5.module
View source
<?php

use Drupal\Core\Routing\RouteMatchInterface;

/**
 * Implements hook_help().
 */
function video_embed_html5_help($route_name, RouteMatchInterface $route_match) {
  switch ($route_name) {
    case 'help.page.video_embed_html5':
      $output = file_get_contents(drupal_get_path('module', 'video_embed_html5') . '/README.md');
      return '<pre>' . $output . '</pre>';
      break;
    default:
  }
}

/**
 * Implements hook_theme().
 */
function video_embed_html5_theme() {
  return [
    'video_embed_html5' => [
      'variables' => [
        'src' => NULL,
        'type' => NULL,
        'autoplay' => FALSE,
        'width' => NULL,
        'height' => NULL,
      ],
      'template' => 'video-embed-html5',
    ],
  ];
}

Functions

Namesort descending Description
video_embed_html5_help Implements hook_help().
video_embed_html5_theme Implements hook_theme().