Ryan Bayne
asked on
CSV File Fails To Upload
Hi
I attached the csv file that fails to upload. Any other csv file will upload just fine.
wp-posts.csv
The difference is probably encoding but I wanted to confirm this or get another reason why $_FILES['file'] shows a fail straight away with this file and not many other csv files I have.
Also what is the best way to properly dedect the reason so I can notify the user?
Thank you for any help
Ryan
I attached the csv file that fails to upload. Any other csv file will upload just fine.
wp-posts.csv
The difference is probably encoding but I wanted to confirm this or get another reason why $_FILES['file'] shows a fail straight away with this file and not many other csv files I have.
Also what is the best way to properly dedect the reason so I can notify the user?
Thank you for any help
Ryan
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Your file size suggestion got me thinking, what if the file size limit being shown to me on the page is not the limit being enforced.
That is what the issue is. I'm displaying the servers limit as 30mb but in fact it is really 2mb. It is a developer plugin I tested to see how easy it could increase the limit. I just assumed it worked and forgot about it.
Thanks for jogging my memory.
That is what the issue is. I'm displaying the servers limit as 30mb but in fact it is really 2mb. It is a developer plugin I tested to see how easy it could increase the limit. I just assumed it worked and forgot about it.
Thanks for jogging my memory.
To turn on error reporting, add the following lines to your php script and then try running your upload again.
Also, the default upload limit for sending files is 2mb. Unless you've changed this, that could also be the problem (the file you've attached is 5.7mb).
Open in new window