diff options
author | Phil Sturgeon <email@philsturgeon.co.uk> | 2012-04-26 23:15:36 +0200 |
---|---|---|
committer | Phil Sturgeon <email@philsturgeon.co.uk> | 2012-04-26 23:15:36 +0200 |
commit | ba4636187a745a287c81517fbc53f2f30fe16d88 (patch) | |
tree | bdcb56cc80e72735d0118f3abf91e04f0dfba5cd /system/helpers | |
parent | cdfbd5281e4dec7278a07943832c2590c1141eb3 (diff) | |
parent | f3b0074b0ccaadef31737cbd6be21ec7272f7538 (diff) |
Fixed conflicts.
Diffstat (limited to 'system/helpers')
-rw-r--r-- | system/helpers/download_helper.php | 3 | ||||
-rw-r--r-- | system/helpers/file_helper.php | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/system/helpers/download_helper.php b/system/helpers/download_helper.php index 19192a147..8b87f8179 100644 --- a/system/helpers/download_helper.php +++ b/system/helpers/download_helper.php @@ -100,6 +100,9 @@ if ( ! function_exists('force_download')) $x[count($x) - 1] = strtoupper($extension); $filename = implode('.', $x); } + + // Clean output buffer + ob_clean(); // Generate the server headers header('Content-Type: '.$mime); diff --git a/system/helpers/file_helper.php b/system/helpers/file_helper.php index 3a373efd3..a5aabecd6 100644 --- a/system/helpers/file_helper.php +++ b/system/helpers/file_helper.php @@ -145,7 +145,7 @@ if ( ! function_exists('delete_files')) { delete_files($path.DIRECTORY_SEPARATOR.$filename, $del_dir, $level + 1, $htdocs); } - elseif ($htdocs === TRUE && ! preg_match('/^(\.htaccess|index\.(html|htm|php))$/', $filename)) + elseif ($htdocs === TRUE && ! preg_match('/^(\.htaccess|index\.(html|htm|php)|web\.config)$/i', $filename)) { @unlink($path.DIRECTORY_SEPARATOR.$filename); } |