headerpage.php 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. <?php
  2. /* For licensing terms, see /license.txt */
  3. /**
  4. * @package chamilo.document
  5. */
  6. /**
  7. * Code
  8. */
  9. // Name of the language file that needs to be included
  10. exit;
  11. $language_file = 'document';
  12. require_once '../inc/global.inc.php';
  13. $noPHP_SELF = true;
  14. $header_file = Security::remove_XSS($_GET['file']);
  15. $path_array = explode('/', str_replace('\\', '/', $header_file));
  16. $path_array = array_map('urldecode', $path_array);
  17. $header_file = implode('/', $path_array);
  18. $nameTools = $header_file;
  19. if (isset($_SESSION['_gid']) && $_SESSION['_gid'] != '') {
  20. $req_gid = '&amp;gidReq='.$_SESSION['_gid'];
  21. $interbreadcrumb[] = array('url' => '../group/group_space.php?gidReq='.$_SESSION['_gid'], 'name' => get_lang('GroupSpace'));
  22. }
  23. $interbreadcrumb[] = array('url' => './document.php?curdirpath='.dirname($header_file).$req_gid, 'name' => get_lang('Documents'));
  24. $interbreadcrumb[] = array('url' => 'showinframes.php?file='.$header_file, 'name' => $header_file);
  25. $file_url_sys = api_get_path(SYS_COURSE_PATH).'document'.$header_file;
  26. $this_section = SECTION_COURSES;
  27. Display::display_header(null, 'Doc');
  28. echo '<div align="center">';
  29. $file_url_web = api_get_path(WEB_COURSE_PATH).$_course['path'].'/document'.$header_file.'?'.api_get_cidreq();
  30. echo "<h1>";
  31. echo '<a href="'.$file_url_web.'" target="blank">'.get_lang('CutPasteLink').'</a></div>';
  32. echo "</h1>";