| Author |
need help for tracking time?
|
Shilpa sathaye
Greenhorn
Joined: May 31, 2006
Posts: 6
|
|
I am developing software apllication using java/jsp,servlets for online aptitude test. I have to track the time for once student loged in for test. Once the time is finished i have to make him exit from application. Since he we will be appearing the test the test screens will be dynamic. What will be best way to keep track for time?? pls suggest.
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56528
|
|
Originally posted by Shilpa sathaye: pls suggest.
"pls" is not a word. Please use real words such as "please" when posting to the forums. Please read this for more info. [ February 07, 2007: Message edited by: Bear Bibeault ]
|
[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
|
 |
Shilpa sathaye
Greenhorn
Joined: May 31, 2006
Posts: 6
|
|
|
I will take note of that.
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56528
|
|
|
Aer you wanting to track the time on the client or on the server?
|
 |
Philip Shanks
Ranch Hand
Joined: Oct 15, 2002
Posts: 189
|
|
Hi Shilpa, Since this is a test situation, you will not want to penalize the test taker with network latency, server response times and page loads eating up their time. I recommend having a cumulative client-side Javascript timer that is tied to a hidden form parameter, triggered with the page load (start the timer in the the body nload() handler, initial value from hidden form parameter), and submitted to the server with form submissions (update the hidden form variable in the form nsubmit() handler) to track and initialize subsequent pages. At a higher level, you might consider using Ajax components in your pages to better minimize the page-to-page latency issues. This will make the test duration appear more seamless, and provide the test taker with a (nearly) uninterrupted test environment. I have had pretty good success with the dojo toolkit for this sort of application. It is simple to associate an HTML form with the XHR object, and update the form parameters dynamically from one request to the next. Breaking the "back" button in a test environment is something you need to think about, but dojo provides workarounds for that too. An additional "plus" is the possibility of making your test work in off-line mode. Good luck! [ February 07, 2007: Message edited by: Philip Shanks ]
|
Philip Shanks, SCJP - Castro Valley, CA
My boss never outsources or has lay-offs, and He's always hiring. I work for Jesus! Prepare your resume!
|
 |
Shilpa sathaye
Greenhorn
Joined: May 31, 2006
Posts: 6
|
|
|
thanks Philip!! I hope working with hidden variable will help.
|
 |
 |
|
|
subject: need help for tracking time?
|
|
|