I have a question about configuring a player in the video module.

In the theme there's a video-play-html5.tpl template, which formats the JW Player.

The question is this--I've used the coding below, along with the pathauto module to change site logos based on content type:

    // Return a file based on the URL alias, else return a default file
    function unique_section_header() {
      $path = drupal_get_path_alias($_GET['q']);
      list($sections, ) = explode('/', $path, 2);
      $section = safe_string($sections);
      $filepath = path_to_theme() . '/images/sections/header-' . $section .'.png';
      if (file_exists($filepath)) {
        $output = $filepath;
      else {
        $output = path_to_theme() . '/images/sections/header-default.png';
      return $output;

    //Make a string safe
    function safe_string($string) {
      $string = strtolower(preg_replace('/[^a-zA-Z0-9_-]+/', '-', $string));
      return $string;

The question is, can something similar be done to change the watermark in the JW Player based on video content type in the html5 player template? (This is assuming that the function even goes in the template; I'm still learning my way around drupal.)

1 Answer 1


video-play-html5.tpl is primarily for the HTML5 player. Are you using JW Player with this template? I think you should use the JW Player module to use JW Player. Using preprocess functions you may be able to change the overlay path.

  • Hi, thanks for answering--it gets tricky because we're using a bought theme with a video section that primarily uses the video module. So we have to work around that. Commented Jun 26, 2012 at 15:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.