ACC SHELL

Path : /www/hosting/oltv.cz/_/utils/upload/
File Upload :
Current File : /www/hosting/oltv.cz/_/utils/upload/index.php

<?php

require('../../include/config.php');
Tracy\Debugger::$maxDepth = 10;
include('./Vimeo.php');


spl_autoload_register(function ($class_name) {
    include $class_name . '.php';
});

$file_name = '../../data/fronta_vimeo/bouracka.mpg';


$lib = new Vimeo('a40ca0e3a983a7053a5cff99cebab63f0268e28e', 'dda13993b350b97afc1aa14ec24d6586f21c0e08', 'ef50ef7f87d19fc3fd69c073ae4d42b0');

/*
try {
    $uri = $lib->upload($file_name);
    $video_data = $lib->request($uri);
    $link = '';
    if($video_data['status'] == 200) {
        $link = $video_data['body']['link'];
    }
    $uploaded[] = array('file' => $file_name, 'api_video_uri' => $uri, 'link' => $link);
    dibi::query()
}
catch (VimeoUploadException $e) {
	dump($e);
}

*/


/* obrazek videa */
$response = $lib->request('/videos/215999155/pictures/',null , 'GET');
dump($response['body']['data'][0]['sizes'][5]['link']);

/* je uz ready? == available */
$response = $lib->request('/videos/215999155/',null , 'GET');
dump($response['body']['status']);

echo 'end';

ACC SHELL 2018