Hello VSSP.
I have solution to your problem.
Get
ffmpeg
Now Extract it to your folder.
The Following Code will show you how you can get duration of Video file.
That one worked for me.
$file= "127808825101 Track 1.wma";
ob_start();
passthru("ffmpeg.exe -i \"{$file}\" 2>&1"); //path to your ffmpeg.exe
$duration = ob_get_contents();
ob_end_clean();
//the full output:
//echo $duration."<br/>";
$search='/Duration: (.*?)[.]/';
$duration=preg_match($search, $duration, $matches, PREG_OFFSET_CAPTURE);
$duration = $matches[1][0];
//i suppose that our video hasn't duration of a day+ :
list($hours, $mins, $secs) = split('[:]', $duration);
echo "Hours: ".$hours." Minutes: ".$mins." Seconds: ".$secs;