You are here

function _background_video_geturl_preprocess_page in Background Video 7

Callback function to get the url of the videos.

1 call to _background_video_geturl_preprocess_page()
background_video_preprocess_page in ./background_video.module
Implements hook_preprocess_HOOK().

File

./background_video.module, line 145
This file provides basic functionality.

Code

function _background_video_geturl_preprocess_page($type) {
  $fid = variable_get('background_video_source_' . $type, NULL);
  if (!empty($fid)) {
    $file = file_load($fid);
    if ($file) {
      return file_create_url($file->uri);
    }
  }
}