close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

How Many File Uploads Per Page

Thread began 1/27/2011 1:55 pm by dlovas275157 | Last modified 1/31/2011 2:40 pm by Jason Byrnes | 3051 views | 12 replies |

dlovas275157

How Many File Uploads Per Page

Is there a limit to the amount of File Upload server behaviors one can use on a insert or update form?

My form has approx 30-40. They seem to start failing after the 20th upload behavior. Any file upload after the 20th does not work. The file is not uploaded nor is the the filename written to the database. Code is identical for all 30-40 behaviors.

Attached is my code.

I'm using the latest extensions. CSS Form Builder 2.0

Attached Files
insertPOST.php.zip
Sign in to reply to this post

Dani Chankhour

Yes, there is a limit that is set on your server.

Can you create a page and add this line of code:

<?php phpinfo(); ?>

And preview the page on your server. This will display information about your server.

Look for this setting:

max_file_uploads

This should tell you if you exceeded the limit that is set on your server.

Sign in to reply to this post

dlovas275157

Dani,

max_file_uploads is set to 20, and my shared host cannot adjust it. Hosting company tells me it cannot be over-ridden by ini set code either.

Does this sound correct, or do you know of any other solutions.

Thanks.

Sign in to reply to this post

Dani Chankhour

Unfortunately i don't because usually it is either something the hosting provider can change or you could use ini to set it. You might have to split the form into two pages.

Sign in to reply to this post

dlovas275157

Dani,

I am trying as you recommended - to split the insert.php form into 2 forms. But I am having trouble with this.

InsertA.php then redirects upon insert to insertB.php. Problem - when I submit insertB.php, it just reloads the page instead of going to the redirect page (detail.php)

Question - should the second form actually be a update page (not an insert page)? And is there some special way to handle the redirects? I need help with the redirects and if they require a .php?id=.... type of link.

Any help is appreciated. THanks - attached is my code.

Attached Files
Archive.zip
Sign in to reply to this post

dlovas275157

Here are screenshots of my Insert Record Server Behaviors if they help troubleshoot.

Thanks again.

Sign in to reply to this post

Jason ByrnesWebAssist

yes, the second form should be an update, not an insert.


In reality, splitting the form like this wont fix the issue you are having, with the form split like this, you will still run into the max upload file size limit when uploading since you still have 9 file uploads happening at the same time.


that is the hearty of the issue, having 9 file uploads at the same time.


You would need to create a main insert form, then create a second file upload form that will upload one file at a time and update the database with the new file name. This is going to require hand coding to determine which column the file name should be stored in and we will not be able to offer support for this part.

Sign in to reply to this post

dlovas275157

Jason,

I have not had issues with this in the past on my host and 9 uploads is far below the 20 max, so I am proceeding with the 2 part insert. I just need help on how to redirect from the initial insert.php (part 1) to the insert/update.php (part 2).

How do I code the redirect on the first insert page to get to the second part (insert/update)?

(I may be wrong, but have built this way in the past without issue)

Sign in to reply to this post

Jason ByrnesWebAssist

It is not a 2 part insert, it is an insert, then update operation.


if you do it as a 2 part insert, you end up with 2 separate records.

on the second page, you need to use an update behavior to update the record that was created on the first page.


when a redirect is not working, it means that there is a php error occurring. add the following code to line one of the page to turn error reporting on:

php:
<?php

error_reporting
(E_ALL);
ini_set('display_errors','on');
?>
Sign in to reply to this post

dlovas275157

Jason,

No errors are shown when I use the error reporting script.

I have insert.php set to redirect to update2.php (which contains the second half of the uploads).

When I submit insert.php it redirects successfully to update2.php BUT it says "no record found"

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...