PHP error 'upload_max_filesize'

Hi,

I am getting error ā€œFile was not uploaded successfully. It may be that the ā€˜upload_max_filesizeā€™ setting in your php.ini file is set to a small numberā€ when I try to upload files of any size through the SuiteCRM import.

I am presently working on my localhost wherein the files were imported by Bitnami Binary files (Direct upload of the Core files to the local host).

I have made the required file upload size change to 60M, Memory limit to 256M, to the main PHP.ini file in my localhost, restarted the server, however, its still giving me the same error.

I have also made changes to import file size limit to the SuitCRM inbuilt file upload size limit under Admin>System Settings to 33554432. It still does not make any difference.

Please let me know what am I missing?

I am unable to get the SuiteCRM core files in my localhost as it was a Binary file installation to make any changes therein.

Is there any way to bypass this error?

Thanks for the help.

In your other posts you detail you could not locate the php.ini, but you have stated here that you were able to edit the file? Can you clarify?

Thanks,

Will.

Hi Thanks for the reply.

Yes, I am unable to locate the SuiteCRM coreā€™s PHP.ini file, however, as I have installed it on a local host using Xampp, it has PHP files included for PHP Module under Xampp, I made the changes in there hoping it might reflect on all, I guess it doesnā€™t work that way.

Could you please guide me to resolve this?

Thanks.

Hi there,

SuiteCRM does not have itā€™s own php.ini file, this is part of your PHP set up on your server.

Did you create the file with the code I suggested in my other post, to confirm you are editing the correct php.ini file?

Thanks,

Will.

Hi Will,

Yes, I created the file as per your suggestion. Just need a clarification, once I create that blank php.ini file & save it on the server, would it configure the codes on its own, I am not sure how this works, this is a first for me.

I am pretty sure I have gone wrong somewhere.

Thanks

Hi Maverick,

You are not creating a php.ini file. The file should be called phpinfo.php.

The code:



<?php
phpinfo();
?>

Will list all the details of your PHP set up, and will show you the location of your php.ini file which PHP using.

Thanks,

Will.

Hi Will,

Sorry for the confusion. I checked the set up thoroughly. Found the php.ini file. I was able to edit the file upload size. I am able to upload the file, however, in my other post, I had stated, I am unable to add fields in the Studio.

Could you help me with that as well?

Thanks

Hi Maverick,

So your file upload/import issue is resolved?

If you are unable to add fields in studio, this is most likely permissions or that you need to set your error reporting so that warnings/notices are not shown(only show errors/FATAL errors).

See the ā€˜Examplesā€™ section in the php manual for more information.

Thanks,

Will.

1 Like

You are a Genius Will. Both the issues got sorted with your help.

Thanks a ton.

Iā€™m having the same issue with importing a single lead as a CSV file. I get the error: File was not uploaded successfully. blah blah. My php.ini upload_max_filesize =16M and post_max_size = 16M. Also, Admin>System Settings>Advanced>Maximum upload size: 33554432 (32M).

BTWā€“Iā€™m having to go through this pain just to duplicate a lead. Sure which suiteCRM allowed me to duplicate records to save a lot of time retypingā€¦

Rob

OK, so I finally thought to look in the sitecrm.log which alerted me to the fact that the upload folder was unwriteable. So there you have it.

But Iā€™d still like to see a DUPLICATE RECORD option for leads, contact, etcā€¦

RD