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

  • Home
  • SEARCH
  • 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 218871
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T18:47:31+00:00 2026-05-11T18:47:31+00:00

here is the situation: In the web application, user selects some options, submits form,

  • 0

here is the situation:
In the web application, user selects some options, submits form, and PDF file is dynamically generated on the server side and offered for download.

The problem:
The generation of PDF file takes quite long (up to 1 minute). Some users think nothing is hapening and keep clicking the submit button again and again increasing server load and slowing it down even further.

I thougt about adding some busy indicator, which would show animated picture and message like “Please wait, your file is being generated”, which seems very easy to do.

But: how to hide this indicator when the file is ready and “file download” dialog pops up? Otherwise, the message stays on screen even after the user has downloaded the file!

Seems very basic requirement, but I’m completely stuck. Thanks for any suggestions!

  • 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-11T18:47:31+00:00Added an answer on May 11, 2026 at 6:47 pm

    I’ve had to do this for something that took a lot longer (converting a video’s format). It might seem like overkill to you but it did work.

    1. Move your PDF code out of process.
    2. When a job is started create a unique job ID and save it to session. Tell the PDF creator this ID.
    3. Make it write a status file (named as the job ID) to the server so that it writes “0% complete” and updates it every few seconds (this part depends on you being able to have a progress metric in your process… If it doesn’t then this won’t work)
    4. Use JS to pull that file down. You can display the progress to the user.
    5. When the progress equals “100% complete”, push them to the PDF’s location. It might help if you name this as the job ID too.*

    *We had another download script that renamed it to a nice name (based on the original video filename) using the content-disposition header, but that’s really up to you!

    Edit: I should add that the waiting page was the result of clicking submit. It was a new pageload but there’s no reason you couldn’t AJAX the whole process, just make sure, as others have said, to disable the submit button on the first click to stop the user going ape on it.

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

Sidebar

Ask A Question

Stats

  • Questions 108k
  • Answers 108k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer You will need to use the new file I/O API… May 11, 2026 at 9:10 pm
  • Editorial Team
    Editorial Team added an answer I believe the problem is that codecs.BOM_UTF8 is a byte… May 11, 2026 at 9:10 pm
  • Editorial Team
    Editorial Team added an answer The statement labs = [[NSMutableArray alloc] init]; makes labs to… May 11, 2026 at 9:10 pm

Related Questions

I'm working on a social network web application, and I got a situation where
Hey all, I'm pulling my hair out on this one. I've checked all my
Am coding an AIR 1.5 app in which I want to do a remote
Does anyone have any suggestions for a best practice or preferred way of rolling
When supporting a new web app in an enterprise environment, it is often necessary

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.