You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

32 lines
595 B

4 years ago
<?php
include './functions.php';
header('Access-Control-Allow-Origin:*');
4 years ago
//header('content-type: video/mp4');
4 years ago
$path = $_REQUEST['path'];
3 years ago
$isProxy = $_REQUEST['isProxy'];
4 years ago
if($path){
returnVideo($path);
}
yimian__log("log_api", array("api" => "video", "timestamp" => date('Y-m-d H:i:s', time()), "ip" => ip2long(getIp()), "_from" => get_from(), "content" => $path));
function returnVideo($path){
3 years ago
if($isProxy == "true"){
header("Location: https://proxy.yimian.xyz/get/?url=".base64_encode($url)."");
3 years ago
}
4 years ago
$url = getVideo($path);
header("Location: $url");
}