コード例 #1
0
ファイル: wimpy.php プロジェクト: noonchild/rsa
function f0($v74, $v84 = "no", $v55 = "no")
{
    global $wimpyApp, $startDir, $v21, $v20, $hide_files, $getMyid3info, $defaultVisualBaseName, $defaultVisualExt, $v31, $v77, $v81, $v69, $hide_folders, $media_types, $v62, $myDataSetup;
    if ($v74 == $v31['path']['physical'] || $v84 == "yes") {
        $v75 = true;
    } else {
        $v75 = false;
    }
    $v53 = opendir($v74);
    $v6 = array();
    $v10 = array();
    $v14 = array();
    $v13 = array();
    $v12 = explode(",", $hide_files);
    $v13 = explode(",", $hide_folders);
    $v19 = explode(",", $media_types);
    $v41 = 0;
    $v35 = $v31['path']['www'];
    while (false !== ($v45 = readdir($v53))) {
        $v48 = $v45;
        $ext = explode('.', $v45);
        $v64 = strtolower($ext[sizeof($ext) - 1]);
        if (!in_array($v45, $v12)) {
            if ($v45 != '.' && $v45 != '..' && @sizeof($ext) > 1 && in_array(strtolower($v64), $v19)) {
                if ($v64 == "xml") {
                    if (stristr(strtolower($v45), "skin") || stristr(strtolower($v45), "config")) {
                        $v43 = "";
                    } else {
                        $v10[count($v10)] = $v45;
                    }
                } else {
                    if ($v64 == "pls" || $v64 == "m3u") {
                        $v10[count($v10)] = $v45;
                    } else {
                        $v10[count($v10)] = $v45;
                    }
                }
            } else {
                if ($v45 != '.' && $v45 != '..') {
                    if (!in_array($v45, $v13)) {
                        if (false !== ($v37 = @opendir($v74 . $v81 . $v45))) {
                            $v6[count($v6)] = $v45;
                        }
                        @closedir($v74 . $v81 . $v45);
                    }
                }
            }
        }
    }
    closedir($v53);
    natcasesort($v6);
    natcasesort($v10);
    $v7 = array_values($v6);
    $v11 = array_values($v10);
    for ($i = 0; $i < sizeof($v7); $i++) {
        $v87 = f3($v7[$i]);
        $v7[$i] = f6($v74 . $v81 . $v87) . "||||";
        $v41++;
    }
    for ($i = 0; $i < sizeof($v11); $i++) {
        $v87 = f3($v11[$i]);
        $ext = explode('.', $v87);
        $v64 = strtolower($ext[sizeof($ext) - 1]);
        if ($v64 == "pls" || $v64 == "m3u") {
            $v11[$i] = $wimpyApp . "%3Faction%3DfeedPlaylist%26theFile%3D" . f6($v74 . $v81 . $v87) . "||||";
        } else {
            $v11[$i] = f6($v74 . $v81 . $v87) . "|" . f10($v74 . $v81 . $v87, "full");
        }
    }
    if ($v62 == "mysql") {
        if (sizeof($v11)) {
            for ($i = 0; $i < sizeof($v11); $i++) {
                array_push($v14, $v11[$i]);
            }
        }
        return $v14;
    } else {
        if (sizeof($v7)) {
            for ($i = 0; $i < sizeof($v7); $i++) {
                array_push($v14, $v7[$i]);
            }
        }
        if (sizeof($v11)) {
            for ($i = 0; $i < sizeof($v11); $i++) {
                array_push($v14, $v11[$i]);
            }
        }
        for ($i = 0; $i < sizeof($v14); $i++) {
            $v77 .= "&item" . $i . "=" . $v14[$i];
        }
        $v100 = sizeof($v14);
        if ($startDir == "") {
            $v112 = $v74 . $v81 . $defaultVisualBaseName . "." . $defaultVisualExt;
            if (is_file($v112)) {
                $v111 = "&visualURL=" . f6($v112);
            } else {
                $v111 = "";
            }
        } else {
            $v112 = $v74 . $v81 . $defaultVisualBaseName . "." . $defaultVisualExt;
            if (is_file($v112)) {
                $v73 = str_replace($v31['path']['physical'], "", $v112);
                $v73 = str_replace($v81, "/", $v73);
                $v111 = "&visualURL=" . ($wimpyApp . "%3Faction%3DgetCoverart%26theFile%3D" . $v73);
            } else {
                $v111 = "";
            }
        }
        $v77 .= "&totalitems={$v100}" . $v111;
        $v77 .= "&datasetup={$myDataSetup}";
        return $v77;
        clearstatcache();
    }
}
コード例 #2
0
ファイル: wimpy.php プロジェクト: noonchild/rsa
function f22($v106, $v54 = false)
{
    global $media_types, $hide_files, $v32, $v91, $startDir;
    $theFile = f23(urldecode($v106));
    $v9 = f10($theFile);
    $v21 = explode(",", $media_types);
    if (!in_array($v9['extension'], $v21)) {
        exit;
    }
    $v14 = explode(",", $hide_files);
    if (in_array($v9['basename'], $v14)) {
        exit;
    }
    $v102 = f25($theFile);
    $v73 = @filesize($v102);
    $v74 = f3($v9['basename']);
    header("Pragma: public");
    header("Expires: Thu, 19 Nov 1981 08:52:00 GMT");
    header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
    header("Cache-Control: no-store, no-cache, must-revalidate");
    header("Cache-Control: private");
    header("Content-Type: audio/x-mpeg, audio/x-mpeg-3, audio/mpeg3");
    if ($v54 == true) {
        header("Content-Disposition: attachment; filename=" . $v9['basename'] . ";");
    }
    header("Content-Transfer-Encoding: binary");
    if ($v73) {
        header("Content-Length: " . $v73, false);
    } else {
        header("Content-Length: 60000000", false);
    }
    f14($v102);
    exit;
}