get_registry(); $session = $appbox->get_session(); $request = http_request::getInstance(); $parm = $request->get_parms('token', 'get', 'type'); try { $datas = ((random::helloToken($parm['token']))); } catch (Exception_NotFound $e) { phrasea::headers(204); } if (!is_string($datas['datas'])) phrasea::headers(204); if (($list = @unserialize($datas['datas'])) == false) { phrasea::headers(500); } try { $appbox = appbox::get_instance(); $auth = new Session_Authentication_Token($appbox, $parm['token']); $session->authenticate($auth); } catch (Exception $e) { phrasea::headers(204); } $gatekeeper = gatekeeper::getInstance(); $gatekeeper->require_session(); $unique_file = false; $n_files = $list['count']; $zip_done = $zip_building = false; $export_name = $list['export_name']; if ($n_files == 1) { $u_file = $list['files']; $u_file = array_pop($u_file); $export_name = $u_file["export_name"]; $u_file = array_pop($u_file['subdefs']); $unique_file = true; $export_name .= $u_file["ajout"] . '.' . $u_file["exportExt"]; $zipFile = p4string::addEndSlash($u_file['path']) . $u_file['file']; $mime = $u_file['mime']; $zip_done = true; } else { $zipFile = $registry->get('GV_RootPath') . 'tmp/download/' . $datas['value'] . '.zip'; $mime = 'application/zip'; } $files = $list['files']; if (isset($parm['get']) && $parm['get'] == '1') { $response = set_export::stream_file($zipFile, $export_name, $mime); $response->send(); set_export::log_download($list, $parm['type']); return; } if (isset($list['complete'])) { if ($list['complete'] == true) $zip_done = true; else $zip_building = true; } phrasea::headers(); ?>
', ''); ?>
() | $v)
{
echo $v['label'] . ' '; $size += $v['size']; } ?> |
get_thumbnail();
if ($thumbnail->is_paysage())
{
$w = 140;
$h = round($w / ($thumbnail->get_width() / $thumbnail->get_height()));
}
else
{
$h = 105;
$w = round($h * ($thumbnail->get_width() / $thumbnail->get_height()));
}
echo ' |