Great, thanks!!This happens only if users upload videos are not MP4. It will not affect the video files and they still work as normal. I will catch this exception in the next update.
You are welcomeConfirmed, works. Thank you...
I've had a lot of issues from the start with this, since changing our server, was always running fine on older server - the change made this difficult, but finally seems to be all ironed out.
Thank you very much again Sonnb.
It seem that you are using PHP < 5.4.0 which requires the 3rd parameter. I recommend to upgrade your PHP version. Or make change to this file: library/PHPVideoToolkit/ProgressHandlerOutput.phpVideo uploads but never converts. Server log shows the error below. What do I need to do?
ErrorException: preg_match_all() expects at least 3 parameters, 2 given - library/PHPVideoToolkit/ProgressHandlerOutput.php:63
Generated By: Unknown Account, Today at 5:12 PM
Stack Trace
#0 [internal function]: XenForo_Application::handlePhpError(2, 'preg_match_all(...', '/var/www/html/f...', 63, Array)
#1 /var/www/html/forums/library/PHPVideoToolkit/ProgressHandlerOutput.php(63): preg_match_all('/\s*Stream\s*\#...', 'Output #0, mp4,...')
#2 /var/www/html/forums/library/PHPVideoToolkit/ProgressHandlerAbstract.php(124): PHPVideoToolkit\ProgressHandlerOutput->_parseOutputData(Array, 'FFmpeg version ...')
#3 /var/www/html/forums/library/PHPVideoToolkit/ProgressHandlerAbstract.php(99): PHPVideoToolkit\ProgressHandlerAbstract->_processOutputFile()
#4 /var/www/html/forums/library/PHPVideoToolkit/Media.php(777): PHPVideoToolkit\ProgressHandlerAbstract->callback()
#5 [internal function]: PHPVideoToolkit\{closure}(Object(PHPVideoToolkit\ExecBuffer), 'FFmpeg version ...', false)
#6 /var/www/html/forums/library/PHPVideoToolkit/ExecBuffer.php(481): call_user_func(Object(Closure), Object(PHPVideoToolkit\ExecBuffer), 'FFmpeg version ...', false)
#7 /var/www/html/forums/library/PHPVideoToolkit/ExecBuffer.php(365): PHPVideoToolkit\ExecBuffer->_run(Object(Closure))
#8 /var/www/html/forums/library/PHPVideoToolkit/Media.php(780): PHPVideoToolkit\ExecBuffer->execute(Object(Closure))
#9 /var/www/html/forums/library/sonnb/XenGalleryVideoUpload/Model/FFMPEG.php(103): PHPVideoToolkit\Media->save('/var/www/html/f...', Object(PHPVideoToolkit\VideoFormat_H264), -2, Object(PHPVideoToolkit\ProgressHandlerOutput))
#10 /var/www/html/forums/library/sonnb/XenGalleryVideoUpload/Deferred/ConvertVideo.php(54): sonnb_XenGalleryVideoUpload_Model_FFMPEG->convert('mp4', Object(PHPVideoToolkit\ProgressHandlerOutput))
#11 /var/www/html/forums/library/XenForo/Model/Deferred.php(294): sonnb_XenGalleryVideoUpload_Deferred_ConvertVideo->execute(Array, Array, 7.9999980926514, '')
#12 /var/www/html/forums/library/XenForo/Model/Deferred.php(428): XenForo_Model_Deferred->runDeferred(Array, 7.9999980926514, '', false)
#13 /var/www/html/forums/library/XenForo/Model/Deferred.php(373): XenForo_Model_Deferred->_runInternal(Array, NULL, '', false)
#14 /var/www/html/forums/deferred.php(23): XenForo_Model_Deferred->run(false)
#15 {main}
Request State
array(3) {
["url"] => string(45) "http://www.websitehere.com/forums/deferred.php"
["_GET"] => array(0) {
}
["_POST"] => array(3) {
["_xfRequestUri"] => string(8) "/forums/"
["_xfNoRedirect"] => string(1) "1"
["_xfResponseType"] => string(4) "json"
}
}
$video_stream_count = preg_match_all('/\s*Stream\s*\#([0-9]+):1s*\(und\)\s*:/i', substr($raw_data, strpos($raw_data, 'Output #0')), $null);
I will do this weekend.Any news on correcting/rebuilding gallery stats? I disabled videos after deleting them all, but forum stats still shows 214 videos.
Compatible with the new XF HTML5 uploader.
A minor update to work with PHP7 .
We use essential cookies to make this site work, and optional cookies to enhance your experience.