File attachement size - Post ID 191787

User 2257017 Photo


Registered User
3 posts

Firstly, apologies as I'm sure this has been asked before but I've searched the form and can't find anything.

My requirement is simple, I want to increase the file size that can be attached to the webform to 30mb, this is 2mb less than my host package will let me use. I'm using Web Form Builder 1.2. I've read the article on how to do this here: http://www.coffeecup.com/help/articles/ … load-size/

My problems:

(1) The article says 'Locate the values for "maxbytes". The values listed are kB.'

Can someone confirm that the maxbytes figure in the form.cfg.php file IS listed in kB as the article suggests? I believe it's actually listed in bytes as the default maximum size of 8129KB in the builder is showing up as 8324096 in the PHP file.

(2) Assuming I'm right on the point above, I've set the maxbytes value to 31457280.

However, when I try to send a file over 8mb through the form the following error is generated: 'Fatal error: Call to a member function SetErrors() on a non-object in /.../fbapp/inc/validator.inc.php on line 22'

This relates to a warning in the validator.inc.php file that the form is trying to send a file that is too big for the server, but as I've said, I've confirmed the size the server allows as 32mb. This maximum file size is the size built into the builder as well so I'm wondering if there something else I need to do in the form.cfg.php file to override this limitation?

I'd appreciate any and all help given.

Steve
User 464893 Photo


Ambassador
1,611 posts

For a start you said you wanted to set the limit to 30 MB which is 30720 KB which the article states

Step 3:
Locate the values for "maxbytes". The values are listed kB. If you do not know how to convert file sizes to kB, see this article.

Step 4:
Enter the new file upload size for each maxbytes you want to change and save the script. That's it!


I read it as entered as KB not Bytes
The Guy from OZ


User 2210454 Photo


Registered User
231 posts

http://www.coffeecup.com/help/articles/ … load-size/ This explains step-by-step how to do it & why it is set up. :cool:
Simon,
“If what you’re doing is not your passion, you have nothing to lose.”
User 2257017 Photo


Registered User
3 posts

Thanks for the responses but unfortunately they don't help my issues.

@ Prism, I know what the article said, I asked is it correct? I'll spell out my issue:

- the maximum size in the Web Form Builder is 8mb, or 8129KB

- this is showing in the PHP file as a maxbyte figure of 8324096

- 8324096kb is not 8mb but 8324096 bytes is

So, if the article is correct (which I am questioning) and the the figure in the PHP file is in kilobytes, why does it not read 8129? Am I missing something?

In any event, even if the article is correct, the figure I entered should have let the form attach as high a file as 3TB. I know my server would not let a 3TB file go through obviously, but it will let 32mb go through so there is no reason why the form is failing at the 8mb point.

@ Simon, I clearly said in my first post that I have read this article and I have taken the steps it's suggested and that's where my issues stem from.

On a side note, the error being generated shouldn't happen either, it should pull the warning text from the validation PHP file and let the client know what's going on by telling them the file size is too big instead of placing PHP error code in front of them.

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.