1

I'm using PHP's FTP functions and I'm having a problem with ftp_put.

Any files under 40MB upload fine through my script, but anything over 40MB doesn't. On the server I'm working on I'm not getting a PHP error to screen to report why.

I'm just wondering if anyone has any suggestions for why it won't print an error, because that is what I need to figure out why it's not uploading.

Supplementary info...

  • PHP errors are turned on
  • Errors aren't suppressed with @ftp_put
  • PHP.INI allows 2GB file uploads
Daniel Williams
  • 2,195
  • 7
  • 32
  • 53

2 Answers2

1

Use error_get_last() to print the last error.

satchcoder
  • 797
  • 5
  • 11
0

Upload limit does not matter here. It's probably a running memory problem. Try the non-bloquant function to send the file chunked: http://php.net/manual/fr/function.ftp-nb-put.php

KyleK
  • 4,643
  • 17
  • 33