Browse Source

custom stylesheet in archive - client denied by server configuration - refs #5967

Cesar Perales 12 years ago
parent
commit
2d69b5d9f4
1 changed files with 2 additions and 1 deletions
  1. 2 1
      main/admin/settings.lib.php

+ 2 - 1
main/admin/settings.lib.php

@@ -314,7 +314,8 @@ function handle_stylesheets() {
                 // Remove path prefix except the style name and put file on disk
                 $zip->create($dir, PCLZIP_OPT_REMOVE_PATH, substr($dir,0,-strlen($safe_style_dir)));
             }
-            $str = '<a class="btn btn-primary btn-large" href="'.str_replace(api_get_path(SYS_ARCHIVE_PATH),api_get_path(WEB_ARCHIVE_PATH),$arch).'">'.get_lang('ClickHereToDownloadTheFile').'</a>';
+            //@TODO: use more generic script to download.
+            $str = '<a class="btn btn-primary btn-large" href="' . api_get_path(WEB_CODE_PATH) . 'course_info/download.php?archive=' . str_replace(api_get_path(SYS_ARCHIVE_PATH), '', $arch) . '">'.get_lang('ClickHereToDownloadTheFile').'</a>';
             Display::display_normal_message($str,false);
         }
     }