Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6737179
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T11:13:07+00:00 2026-05-26T11:13:07+00:00

I’m attempting to upload documents to my server using the technique describe on this

  • 0

I’m attempting to upload documents to my server using the technique describe on this blog

All has gone well, and I am able to upload documents just fine. The only snag is when I attempt to upload a file which exceeds the upload limit which is defined in my web.config as so….

<location path="Documents/Documents/Add">
   <system.web>
      <httpRuntime maxRequestLength="25600"/>
   </system.web>   
</location>

The problem is that I am not getting a response from the server. In fact, when debugging in Visual Studio, the action is not even hit!

Further investigation in fiddler shows that I’m getting a…

504: ReadResponse() failed: The server did not return a response for this request.  

….but I am only getting this in Chrome when fiddler is running. If fiddler isn’t running chrome simply sees “Failed” with no status code, and the error() of the $().ajax form call isn’t hit.

Also this SO post has exactly the same issue. However, I want to know how I can give feedback to the user when the file size is exceeded as currently the “loading.gif” is just spinning as no error response is being raised.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T11:13:08+00:00Added an answer on May 26, 2026 at 11:13 am

    Check this SO question about client side checking of file size to be able to catch it before trying to upload a file that is too big.
    Find size of file behind download link with jQuery

    EDIT

    The server will throw an exception if the filesize is larger than your setting in the web.config file so you can do a couple things if you want to handle it server side.

    1) You can increases the max file size and then your upload code can validate a smaller size and return a failure if it is too large. Of course if they try for something even bigger than your new size it will still fail.

    2) Catch the error in the global.asax file and do something with it. Set a response header, return false or whatever. Check Catching "Maximum request length exceeded" to get you started on this option.

    3) Handle it client side with the JQuery option I put up earlier or use Flash to check the size.

    Basically waiting for the server to tell you the file is too large is usually too late. The file has to go all the way there before it can tell you oops too big. This incurs a larger hit on your server. It is usually better to find a way to check it on the client if possible.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I am using Paperclip to handle profile photo uploads in my app. They upload
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I want to count how many characters a certain string has in PHP, but
For some reason, after submitting a string like this Jack’s Spindle from a text
Basically, what I'm trying to create is a page of div tags, each has
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
this is what i have right now Drawing an RSS feed into the php,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.