| @@ 4556-4563 (lines=8) @@ | ||
| 4553 | ||
| 4554 | //make htaccess with allow from all, and file index.html into temp/audio |
|
| 4555 | $htaccess = api_get_path(SYS_ARCHIVE_PATH).'temp/audio/.htaccess'; |
|
| 4556 | if (!file_exists($htaccess)) { |
|
| 4557 | $htaccess_content="order deny,allow\r\nallow from all\r\nOptions -Indexes"; |
|
| 4558 | $fp = @ fopen(api_get_path(SYS_ARCHIVE_PATH).'temp/audio/.htaccess', 'w'); |
|
| 4559 | if ($fp) { |
|
| 4560 | fwrite($fp, $htaccess_content); |
|
| 4561 | fclose($fp); |
|
| 4562 | } |
|
| 4563 | } |
|
| 4564 | ||
| 4565 | //encript temp name file |
|
| 4566 | $name_crip = sha1(uniqid());//encript |
|
| @@ 176-185 (lines=10) @@ | ||
| 173 | ||
| 174 | //make htaccess with allow from all, and file index.html into temp/images |
|
| 175 | $htaccess=api_get_path(SYS_ARCHIVE_PATH).'temp/images/.htaccess'; |
|
| 176 | if (!file_exists($htaccess)) { |
|
| 177 | ||
| 178 | $htaccess_content="order deny,allow\r\nallow from all\r\nOptions -Indexes"; |
|
| 179 | ||
| 180 | $fp = @ fopen(api_get_path(SYS_ARCHIVE_PATH).'temp/images/.htaccess', 'w'); |
|
| 181 | if ($fp) { |
|
| 182 | fwrite($fp, $htaccess_content); |
|
| 183 | fclose($fp); |
|
| 184 | } |
|
| 185 | } |
|
| 186 | ||
| 187 | $html_index=api_get_path(SYS_ARCHIVE_PATH).'temp/images/index.html'; |
|
| 188 | if (!file_exists($html_index)) { |
|
| @@ 188-195 (lines=8) @@ | ||
| 185 | } |
|
| 186 | ||
| 187 | $html_index=api_get_path(SYS_ARCHIVE_PATH).'temp/images/index.html'; |
|
| 188 | if (!file_exists($html_index)) { |
|
| 189 | $html_index_content="<html><head></head><body></body></html>"; |
|
| 190 | $fp = @ fopen(api_get_path(SYS_ARCHIVE_PATH).'temp/images/index.html', 'w'); |
|
| 191 | if ($fp) { |
|
| 192 | fwrite($fp, $html_index_content); |
|
| 193 | fclose($fp); |
|
| 194 | } |
|
| 195 | } |
|
| 196 | ||
| 197 | //encript temp name file |
|
| 198 | $name_crip=sha1(uniqid());//encript |
|