Już mówie...
Jak wrzuce film to wszystko jest wporządku wgrywa sie itp. ale gdy już chcę ten film obejrzeć to nie ma odtwarzacza tylko to się wyświetla.
Kod
Warning: Invalid argument supplied for foreach() in /home/lsmods/domains/ls2009-mods.pl/public_html/filmy/includes/functions.php on line 1511
Zobaczcie sami:
http://filmy.ls2009-mods.pl/video/R752WAGD3K8K/dsfKowałek kodu:
Kod
/**
* Function use to get video files
*/
function get_video_file($vdetails,$return_default=true,$with_path=true,$multi=false,$count_only=false,$hq=false)
{
# checking if there is any other functions
# available
if(is_array($Cbucket->custom_video_file_funcs))
foreach($Cbucket->custom_video_file_funcs as $funcs)
if(function_exists($func))
return $func($vdetails);
#Now there is no function so lets continue as
$vid_files = glob(VIDEOS_DIR."/".$vdetails['file_name']."*");
#replace Dir with URL
TO! 1511 ---> foreach($vid_files as $file) <---
{
$files_part = explode('/',$file);
$video_file = $files_part[count($files_part)-1];
if($with_path)
$files[] = VIDEOS_URL.'/'.$video_file;
else
$files[] = $video_file;
}
if(count($files)==0 && !$multi && !$count_only)
{
if($return_default)
{
if($with_path)
return VIDEOS_URL.'/no_video.flv';
else
return 'no_video.flv';
}else{
return false;
}
}else{
if($multi)
return $files;
if($count_only)
return count($files);
foreach($files as $file)
{
if($hq)
{
if(getext($file)=='mp4')
{
return $file;
break;
}
}else{
return $file;
break;
}
}
return $files[0];
}
}
/**
* FUnction used to get HQ ie mp4 video
*/
Linijka 1511:
foreach($vid_files as $file)Może ktoś mi pomóc?