mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-05 19:42:38 +02:00
This commit is contained in:
parent
673b7f0316
commit
66c7658f0f
10 changed files with 193 additions and 79 deletions
|
@ -114,9 +114,9 @@ function checkVideosDir()
|
|||
function getVideosDir()
|
||||
{
|
||||
global $isStandAlone, $global;
|
||||
if(empty($isStandAlone)){
|
||||
if (empty($isStandAlone)) {
|
||||
return Video::getStoragePath();
|
||||
}else{
|
||||
} else {
|
||||
return "{$global['systemRootPath']}videos/";
|
||||
}
|
||||
}
|
||||
|
@ -1220,3 +1220,14 @@ function findMP3File($folderPath)
|
|||
// Return false if no .mp4 file is found
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
// Helper function to read JSON files
|
||||
function readJsonFile($filePath)
|
||||
{
|
||||
if (!file_exists($filePath)) {
|
||||
return null;
|
||||
}
|
||||
$content = file_get_contents($filePath);
|
||||
return json_decode($content, true);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue