Here are the errors that kept popping out when I load a page that contains View:Block of videos using Video.JS

Notice: Undefined index: filemime in template_preprocess_videojs() (line 33 of /var/www/drupal7/sites/all/modules/videojs/includes/videojs.theme.inc).
Notice: Undefined property: stdClass::$uri in file_validate_is_image() (line 1746 of /var/www/drupal7/includes/file.inc)

I created a new content type to upload videos. In Managed Display I selected the Format as Video Player. (Refer attachment: Video Managed Display.png).

I configure View:Block to display the video content in one of my page and that's how I got the above 2 error message that kept showing. Please refer to attached file "Errors.png"

My configuration-->Media-->Videos-->Player, I configured the extension of the respective Video extension to HTML5 Player and VidoeJS as my video player.

I have also included the 2 files mentioned in the errors.png. I have search the entire internet and failed to get a solution. Really appreciate if someone encounter the same problem and got a solution able to help me here.

Desperate Drupal Noob
Danny.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Jorrit’s picture

Status: Active » Postponed (maintainer needs more info)

For some reason, the information given to the Video.js module is wrong. Could you add the following line to videojs.theme.inc on a new line after function template_preprocess_videojs(&$vars) {:

var_dump($vars);

This will cause some data to be displayed on the screen. Could you post that here?

Jorrit’s picture

Could you also explain how the view is configured?

hendry.a’s picture

subscribe

Hi, I have similar problem but version for videojs is different(videojs-7.x-2.x-dev) and this is code display in my page after i follow comment #1 :

array(18) {
["items"]=> array(2) {
["flv"]=> array(6) {
["filename"]=> string(8) "Song.flv"
["filepath"]=> string(29) "s3://videos/original/Song.flv"
["url"]=> string(69) "http://video.indo.com.s3.amazonaws.com/videos/original/Song.flv"
["uri"]=> string(29) "s3://videos/original/Song.flv" ["filemime"]=> string(11) "video/x-flv"
["extension"]=> string(3) "flv" }
["thumbnail"]=> array(0) { }
}
["player_id"]=> string(8) "video-33"
["attributes"]=> array(2) {
["width"]=> string(3) "640"
["height"]=> string(3) "360"
}
["theme_hook_suggestions"]=> array(0) { }
["zebra"]=> string(3) "odd"
["id"]=> int(1)
["directory"]=> string(25) "sites/all/modules/videojs"
["classes_array"]=> array(1) {
[0]=> string(7) "videojs"
}
["attributes_array"]=> array(0) { }
["title_attributes_array"]=> array(0) { }
["content_attributes_array"]=> array(0) { }
["title_prefix"]=> array(0) { }
["title_suffix"]=> array(0) { }
["user"]=> object(stdClass)#6 (23) {
["uid"]=> string(1) "1"
["name"]=> string(5) "admin"
["pass"]=> string(55) "$S$DgNiAbhhDV3nMhrgf11581h1yyLaQwBUg3jRoXEZoizsExVsuuRC"
["mail"]=> string(16) "drupal@gmail.com"
["theme"]=> string(0) ""
["signature"]=> string(0) ""
["signature_format"]=> NULL
["created"]=> string(10) "1329121135"
["access"]=> string(10) "1330509306"
["login"]=> string(10) "1330419949"
["status"]=> string(1) "1"
["timezone"]=> string(16) "Asia/Krasnoyarsk"
["language"]=> string(0) ""
["picture"]=> string(1) "0"
["init"]=> string(16) "drupal@gmail.com"
["data"]=> bool(false)
["sid"]=> string(43) "k38OrVENtnmOoAdG0RhI-k7RAbmS5LWWfroddOOynBQ"
["ssid"]=> string(0) ""
["hostname"]=> string(9) "127.0.0.1"
["timestamp"]=> string(10) "1330509475"
["cache"]=> string(10) "1330420743"
["session"]=> string(1239) "dblog_overview_filter|a:0:{}messages|a:1:{s:5:"error";a:4:{i:0;s:296:"Notice: Undefined index: filemime in template_preprocess_videojs() (line 34 of C:\xampp-win32-1.7.7-VC9\xampp\htdocs\mydrupal\sites\all\modules\videojs\includes\videojs.theme.inc).";i:1;s:267:"Notice: Undefined property: stdClass::$uri in file_validate_is_image() (line 1746 of C:\xampp-win32-1.7.7-VC9\xampp\htdocs\mydrupal\includes\file.inc).";i:2;s:296:"Notice: Undefined index: filemime in template_preprocess_videojs() (line 34 of C:\xampp-win32-1.7.7-VC9\xampp\htdocs\mydrupal\sites\all\modules\videojs\includes\videojs.theme.inc).";i:3;s:267:"Notice: Undefined property: stdClass::$uri in file_validate_is_image() (line 1746 of C:\xampp-win32-1.7.7-VC9\xampp\htdocs\mydrupal\includes\file.inc).";}}"
["roles"]=> array(2) {[2]=> string(18) "authenticated user" [3]=> string(13) "administrator" }
}
["db_is_active"]=> bool(true)
["is_admin"]=> bool(true)
["logged_in"]=> bool(true)
["is_front"]=> bool(true)
}

thank you.

Regards Hendry

Jorrit’s picture

Status: Postponed (maintainer needs more info) » Fixed

This was a bug in the Video module. Please try the next 7.x-2.x-dev version of the Video module.

hendry.a’s picture

Status: Fixed » Postponed (maintainer needs more info)

I have been using video module "video-7.x-2.x-dev" but error message still display (media player works well).
At below is module that i install in my drupal:
1. Video (video-7.x-2.x-dev)
2. Video JS (videojs-7.x-2.x-dev) & VideoJS Library (video-js-3.1.0)
3. Video Preset (video_presets-7.x-2.1)

thank before for your quick repply.

Jorrit’s picture

You should wait one day until the code with my fix is turned into the next -dev release. This does not happen instantly, Drupal.org creates -dev releases once a day.

dannycheah’s picture

Sorry Jorrit for the late reply. Here is the output after I added the var_dump($vars); as instructed.

array(18) {
["items"]=> array(2) {
["mov"]=> array(6) {
["filename"]=> string(36) "Student_Alpha-Starfish(09-01-05).mov"
["filepath"]=> string(61) "public://videos/original/Student_Alpha-Starfish(09-01-05).mov"
["url"]=> string(118) "http://www.alphafriends.org.my/accelerate/sites/default/files/videos/ori..."
["uri"]=> string(61) "public://videos/original/Student_Alpha-Starfish(09-01-05).mov"
["filemime"]=> string(15) "video/quicktime" ["extension"]=> string(3) "mov" }
["thumbnail"]=> array(0) { }
}
["player_id"]=> string(9) "video-286"
["attributes"]=> array(2) {
["width"]=> string(3) "320" ["height"]=> string(3) "240"
}
["theme_hook_suggestions"]=> array(0) { }
["zebra"]=> string(3) "odd" ["id"]=> int(1)
["directory"]=> string(25) "sites/all/modules/videojs"
["classes_array"]=> array(1) { [0]=> string(7) "videojs" }
["attributes_array"]=> array(0) { }
["title_attributes_array"]=> array(0) { }
["content_attributes_array"]=> array(0) { }
["title_prefix"]=> array(0) { } ["title_suffix"]=> array(0) { }
["user"]=> object(stdClass)#8 (4) {
["uid"]=> int(0) ["hostname"]=> string(13) "183.78.10.235"
["roles"]=> array(1) { [1]=> string(14) "anonymous user"
}
["cache"]=> int(0) } ["db_is_active"]=> bool(true)
["is_admin"]=> bool(false) ["logged_in"]=> bool(false)
["is_front"]=> bool(false) }

dannycheah’s picture

FileSize
47.41 KB
32.74 KB

Here are the snapshot (attached: Configure Views.png) of how I configure my views. I'm not sure if this is what you are asking. If not please let me know and I will try my best to furnished you with the information you needed.

Also, now i am getting a new error when I click on Update Preview in the edit View page. Please refer to attached "Update Preview.png"

dannycheah’s picture

Hi Jorrit,

I am now using the latest 7.x-2.x-dev released on 2012-Mar-05. It solved my problem now. Will continue to test and see if there are any more problems.

Thank you very much for your help.

Regards,
Danny

Jorrit’s picture

Status: Postponed (maintainer needs more info) » Fixed

I am going to mask this one as fixed. If you encounter another error, please reopen this issue or open a new one.

hendry.a’s picture

thank you jorrit..new video module dev solved the problem..

dannycheah’s picture

Dear Jorrit,

So far it has work flawlessly. I will keep you updated if there is any issues with the module. Once again thank you.

Regards,
Danny.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.