I am creating a service involving on-line administration of a series of psych tests. The design goal is to present the client with a 'look and feel' akin to the usual paper-and-pencil environment. This means the client can browse all the items on a test, answer them in any order (s)he wishes and change one's answers, just as is the case with all standardized testing. Further, the client is under no requirement that a test be completed at a 'sitting', but (s)he cannot select another test section without first finishing the current one. Once a test section is completed, it cannot be accessed - ie, that test booklet is 'handed in'.
For these reasons among others, we opted for server side handling rather than the usual client side handling - one response at a time.
The environment involves PHP5, CSS with XHTML 1.1 and PostgreSQL8.3.
Once authenticated, a session is started each time a new test is selected or an existing one called up for completion.
All of this works very smoothly but with one probable glitch.
We have provided a session length of 7200 (2 hours) which is at least twice the time any one section would take to complete.
What is going to happen when a client leaves the site and does not return before the session expires?
Any responses provided on the current test are going to be lost. At present, responses are transferred to the database only when the test is completed or the client requests that the work be saved at that point in time.
Ideally, what I need is a way to insure against this situation happening, but I do not understand how or even if that could be accomplished.
Suggestions, anyone?