transferFiles.php 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <?php
  2. /* $Id: transferFiles.php 2893 2007-04-14 13:20:30Z b4rt $ */
  3. /*******************************************************************************
  4. LICENSE
  5. This program is free software; you can redistribute it and/or
  6. modify it under the terms of the GNU General Public License (GPL)
  7. as published by the Free Software Foundation; either version 2
  8. of the License, or (at your option) any later version.
  9. This program is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. To read the license please visit http://www.gnu.org/copyleft/gpl.html
  14. *******************************************************************************/
  15. // prevent direct invocation
  16. if ((!isset($cfg['user'])) || (isset($_REQUEST['cfg']))) {
  17. @ob_end_clean();
  18. @header("location: ../../index.php");
  19. exit();
  20. }
  21. /******************************************************************************/
  22. // transfer functions
  23. require_once('inc/functions/functions.transfer.php');
  24. // init template-instance
  25. tmplInitializeInstance($cfg["theme"], "page.transferFiles.tmpl");
  26. // init transfer
  27. transfer_init();
  28. // init ch-instance
  29. $ch = ClientHandler::getInstance(getTransferClient($transfer));
  30. // set file vars
  31. transfer_setFileVars();
  32. // file-prio
  33. if (($cfg["enable_file_priority"] == 1) && ($cfg["supportMap"][$ch->client]['file_priority'] == 1) && (!isTransferRunning($transfer))) {
  34. require_once("inc/functions/functions.fileprio.php");
  35. $tmpl->setvar('filePrio', getFilePrioForm($transfer, true));
  36. $tmpl->setvar('file_priority_enabled', 1);
  37. } else {
  38. $tmpl->setvar('file_priority_enabled', 0);
  39. }
  40. // title + foot
  41. tmplSetFoot(false);
  42. tmplSetTitleBar($transferLabel." - Files", false);
  43. // iid
  44. tmplSetIidVars();
  45. // parse template
  46. $tmpl->pparse();
  47. ?>