| 123456789101112131415161718192021 |
- <?php
- if(isset($_POST["from"]) AND $_POST["from"] == "video.cut"){
- require_once "../core/controllers/session.php";
- $execute = fichier::cut();
- if($execute["success"] == TRUE){
- unlink("../video/" . $_POST['md5']. ".mp4");
- rename("../video/_" . $_POST['md5']. ".mp4", "../video/" . $_POST['md5']. ".mp4");
- $durationInSeconds = fichier::getVideoDuration("../video/" . $_POST["md5"]. ".mp4");
- fichier::updateTime($_POST["id"], $durationInSeconds);
- } else {
- core::print_r($execute);
- exit();
- }
- header("Location: /edit/".$_POST["hash"]);
- exit();
- } else {
- header("Location: /");
- exit();
- }
|