Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Apr 28th, 2006, 6:20 PM   #1
ktsirig
Programmer
 
Join Date: Oct 2005
Posts: 54
Rep Power: 3 ktsirig is on a distinguished road
How is this done? PHP, Javascript or both?

Hi all!
I have a php page which contains a form. The user enters data and then the data is processed to give some results. What I would like to have is a page inbetween, that says, for instance, "Your job is being processed" or something similar, and then, when the job is done, refresh itself to show the results. I have seen it in many websites, but I don't know what I need to get me started...
ktsirig is offline   Reply With Quote
Old Apr 28th, 2006, 8:35 PM   #2
PhilBon
Hobbyist Programmer
 
PhilBon's Avatar
 
Join Date: Nov 2005
Posts: 172
Rep Power: 3 PhilBon is on a distinguished road
Send a message via AIM to PhilBon Send a message via MSN to PhilBon
I would think to have the form go to that page and then have a header() to go to the next page, just make sure you post the information you want between the middle and last page.
PhilBon is offline   Reply With Quote
Old Apr 29th, 2006, 6:10 AM   #3
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
In the normal course of events with http transactions the server never initiates. That means your server has to plant something in the client-side material that initiates. Whether that's a periodic automatic refresh, series of redirections, or script is up to you. If it's script, the browser must be able and agreeable about executing it. In any case, it's an intrusion on the client's property, equipment, and time. Nothing to keep him/her from tossing you in the trash if it gets intrusive. I would.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote
Old Apr 29th, 2006, 1:25 PM   #4
JavaMan
Newbie
 
Join Date: Oct 2005
Posts: 29
Rep Power: 0 JavaMan is on a distinguished road
In php, you could just make it display "Your job is being processed" and in a given amount of seconds redirect to another page and send data to that page so it shows the results.
JavaMan is offline   Reply With Quote
Old Apr 29th, 2006, 1:43 PM   #5
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote
Old Apr 30th, 2006, 4:05 PM   #6
ktsirig
Programmer
 
Join Date: Oct 2005
Posts: 54
Rep Power: 3 ktsirig is on a distinguished road
Hi, thank you all for your time!
Actually, what I do is not just take user's input and print it, but i use the data which the user sends as input to an external program that I call through PHP. This program is a bit slow, so I thought of using such a page (not a very complicated one) so that the user will see a message like "Jour job is being processed", and then, when the job is done, the page will refresh and show the results or will redirect to the results page.
ktsirig is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 9:28 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC