Moved all file-related functions from BasicStor into StoredFile class.
Got rid of all the stuff related to GUNID hex-to-int conversion. Commented out lots of functions that are either not in use or will no longer work. Pypo: made things more generic and pluggable, added documentation. Added the PHP scripts to serve the right info back to pypo.
This commit is contained in:
parent
35dc3fd01f
commit
8a58df3093
32 changed files with 2233 additions and 2000 deletions
|
@ -137,20 +137,21 @@ if (isset($_REQUEST['popup']) && is_array($_REQUEST['popup'])){
|
|||
break;
|
||||
|
||||
case "PL.downloadExportedFile":
|
||||
$exportedPlaylist = $uiBrowser->gb->exportPlaylistOpen($uiBrowser->sessid,
|
||||
BasicStor::GunidFromId($_REQUEST['id']),
|
||||
$_REQUEST['playlisttype'],
|
||||
$_REQUEST['exporttype']=='playlistOnly'?true:false);
|
||||
$fp = fopen($exportedPlaylist['fname'],'r');
|
||||
if (is_resource($fp)) {
|
||||
header("Content-Type: application/octet-stream");
|
||||
header("Content-Length: " . filesize($exportedPlaylist['fname']));
|
||||
header('Content-Disposition: attachment; filename="playlist.tar"');
|
||||
header("Content-Transfer-Encoding: binary\n");
|
||||
fpassthru($fp);
|
||||
$uiBrowser->gb->exportPlaylistClose($exportedPlaylist['token']);
|
||||
}
|
||||
//$Smarty->display('popup/PLAYLIST.downloadExportedFile.tpl');
|
||||
|
||||
// $exportedPlaylist = $uiBrowser->gb->exportPlaylistOpen($uiBrowser->sessid,
|
||||
// BasicStor::GunidFromId($_REQUEST['id']),
|
||||
// $_REQUEST['playlisttype'],
|
||||
// $_REQUEST['exporttype']=='playlistOnly'?true:false);
|
||||
// $fp = fopen($exportedPlaylist['fname'],'r');
|
||||
// if (is_resource($fp)) {
|
||||
// header("Content-Type: application/octet-stream");
|
||||
// header("Content-Length: " . filesize($exportedPlaylist['fname']));
|
||||
// header('Content-Disposition: attachment; filename="playlist.tar"');
|
||||
// header("Content-Transfer-Encoding: binary\n");
|
||||
// fpassthru($fp);
|
||||
// $uiBrowser->gb->exportPlaylistClose($exportedPlaylist['token']);
|
||||
// }
|
||||
// //$Smarty->display('popup/PLAYLIST.downloadExportedFile.tpl');
|
||||
break;
|
||||
|
||||
case "SCHEDULER.addItem":
|
||||
|
@ -354,10 +355,10 @@ if ($uiBrowser->userid) {
|
|||
$Smarty->assign('showFile', TRUE);
|
||||
break;
|
||||
|
||||
case "_analyzeFile":
|
||||
$Smarty->assign('_analyzeFile', $uiBrowser->analyzeFile($uiBrowser->id, 'text'));
|
||||
$Smarty->assign('showFile', TRUE);
|
||||
break;
|
||||
// case "_analyzeFile":
|
||||
// $Smarty->assign('_analyzeFile', $uiBrowser->analyzeFile($uiBrowser->id, 'text'));
|
||||
// $Smarty->assign('showFile', TRUE);
|
||||
// break;
|
||||
|
||||
case "changeStationPrefs":
|
||||
$Smarty->assign('dynform', $uiBrowser->changeStationPrefs($ui_fmask['stationPrefs']));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue