MG 1.1 Problem Uploading Videos

When I tried to upload a video bigger than 20 mb I got this error

ErrorException: fopen(): Filename cannot be empty - library/XenGallery/VideoInfo/Preparer.php:21

and the error code in admin area is:

Stack Trace
#0 [internal function]: XenForo_Application::handlePhpError(2, 'fopen(): Filena...', '/home/tvnewsit/...', 21, Array)
#1 /home/tvnewsit/public_html/library/XenGallery/VideoInfo/Preparer.php(21): fopen('', 'rb')
#2 /home/tvnewsit/public_html/library/XenGallery/Model/Media.php(2777): XenGallery_VideoInfo_Preparer->__construct('')
#3 /home/tvnewsit/public_html/library/XenGallery/ControllerPublic/File.php(151): XenGallery_Model_Media->requiresTranscoding('')
#4 /home/tvnewsit/public_html/library/XenForo/FrontController.php(347): XenGallery_ControllerPublic_File->actionDoUpload()
#5 /home/tvnewsit/public_html/library/XenForo/FrontController.php(134): XenForo_FrontController->dispatch(Object(XenForo_RouteMatch))
#6 /home/tvnewsit/public_html/index.php(13): XenForo_FrontController->run()
#7 {main}
Request State
array(3) {
["url"] => string(155) ""
["_GET"] => array(4) {
["hash"] => string(32) "edf6cdfded4c54f3521c88cf6c775300"
["content_type"] => string(16) "xengallery_media"
["upload_type"] => string(12) "video_upload"
["key"] => string(12) "video_upload"
["_POST"] => array(6) {
["Filename"] => string(36) "Cuando El Amor No Alcanza Cap 19.mp4"
["_xfResponseType"] => string(4) "json"
["_xfSessionId"] => string(32) "ba89d7d75468431d4845ef4cfbb0b1e4"
["_xfNoRedirect"] => string(1) "1"
["content_data"] => array(1) {
["category_id"] => string(1) "3"
["_xfToken"] => string(8) "********"

Any idea on this?


Chris D

XenForo developer
Staff member
If this only happens on video files above a certain size, I do wonder if this could be hitting upload_max_filesize and post_max_size limits in PHP.

Could you check your php.ini file and let me know what those values are?

Chris D

XenForo developer
Staff member
There's a small change we have made in the next release, but it's unlikely to fix this exact problem.

We can't actually reproduce the exact issue. I'm going to start a Conversation with you and attach the updated file. You might want to upload that and try again.

At the very least I would hope that it might reveal to us a more clear cause for the error.

Chris D

XenForo developer
Staff member
I have been able to reproduce this issue now but only if the upload_max_filesize is too low. The updated file I sent you will display a different error and no longer log an exception. The error you will get is "The uploaded file is too large for the server to process."

A few things to check:
  • After making the changes, did you restart the web server?
  • Do you see the correct upload_max_filesize and post_max_size values if you go to yoursite/admin.php?tools/phpinfo
  • If not, are you certain you made the changes in the correct php.ini file? You can check on the above page the path to the configuration file being used under "Loaded Configuration File"

Chris D

XenForo developer
Staff member
Is the problem still happening in the latest 1.1 release? Release Candidate 1?

If you go to your Admin CP > Applications > Gallery Options > Video Options and then click Save Changes, do you get any errors about FFMPEG compatibility?