Interrupt session at configed time

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Kevin Hamilton

    Interrupt session at configed time

    I am working on a testing/quizzing program where I will present one
    question at a time. However, I want to set a time limit for the test
    so that no matter what question the student is on, the test will end
    and redirect to a score page.

    Does php have the ability to provide this? My host doesn't support
    pcntl_alarm() so I need another mechanism.

    Maybe an all php environment isn't the right solution? Should I be
    looking at other solutions?

    I would prefer server side control to minimize browser/machine
    dependencies.

    Any pointers to snippets would be greatly appreciated.
  • CNerd2025

    #2
    Re: Interrupt session at configed time

    Try looking at session variables. Sessions are king in PHP. Also, try
    saving in a variable the start time and then add the testing time to
    it. Then when the appointed time comes, just feed the client a header.
    You probably will need PHP and JavaScript to accomplish this. There are
    numerous other ways to solve this problem, but I think you have the
    right idea.

    Comment

    Working...