Php скрипт загрузки файлов | php script for file upload

Я долго не мог понять почему не могу загрузить файл на сервер и наконец нашел причину
Делюсь скриптом загрузки файлов

  • :white_check_mark: Требует X-API-Key заголовок
  • :white_check_mark: Проверка размера файлов
  • :white_check_mark: Ограничение по типам файлов
  • :white_check_mark: Безопасная генерация имен файлов
  • :white_check_mark: Корректная обработка multipart данных

For a long time I couldn’t understand why I couldn’t upload a file to the server and finally found the reason
I’m sharing a file upload script

  • :white_check_mark: Requires X-API-Key header
  • :white_check_mark: File size check
  • :white_check_mark: File type limit
  • :white_check_mark: Safe file name generation
  • :white_check_mark: Correct processing of multipart data


uploadFilePhp.zip (8.9 KB)

2 Likes

What if I want to use another site different from this one, will it work?

Use any website, it doesn’t matter to the script.

Okay, thanks.

The only problem is that the site encrypts data at transfer, and therefore uploading might hit a firewall that prevent it from reaching the folder I guess. I have tried it on MEGA.nz It does not work.

Any idea please?

MEGA.nz is not a hosting service.
MEGA.nz uses its own file management system.

Okay great one. That’s where I miss
Thank you for the clarification.


Back to Flipabit >
Copyright © 2018. Flipabit Team. All rights reserved.