upload does not send files after a certain size

1

Colleagues.

I have a part of the system that sends pdf files to the server:

list($arquivo, $extensao) = explode(".",$arquivoNome);
    $codificar = md5(date('h:i').$arquivo).".".$extensao;
    $dirArquivo = "uploads/pdf/";
    $upArquivo = $dirArquivo . basename($codificar);

    if(move_uploaded_file($arquivoTemp, $upArquivo)){
      ......
}

The problem is that if the file is light, it works, but if the file is over 1MB it does not send.

    
asked by anonymous 28.04.2016 / 16:46

1 answer

2

If the uploaded files are larger than the server-defined value, change the upload_max_filesize in php.ini to an appropriate value and to finish the process restart apache.

upload_max_filesize=5M
  • upload_max_filesize is the size of uploads sent to the server.

  • max_file_uploads is the maximum number of files sent in the request.

28.04.2016 / 16:49