PHP: formüler girişi için Timer

0 Cevap

PHP web tabanlı sınav uygulaması kodlama duyuyorum.

  • Sınava göre sorular ile modülleri bir dizi seçmek zorunda.
  • Bir modül tek-tek-FORMULAR olarak temsil edilir.
  • Her modül için o örneğin 30 dakika var.

I will achive that if the 30 minutes are over, the state of the form (answered and unanswered questions will be stored in a database) and the form will be closed e.g. redirect to menu page. I tried something like that:

<?php
set_time_limit('30000');
function redirect(){
  //...
}
$i = 1;
while($i <= 45){
  sleep('60');
  callthis();
  flush();
  $i++;
}
?>

Benim hoster set_time_limit anda çünkü PHP'nin Güvenli Mod kullanılan olamazdı.

What is the most reliable server-based solution (no Javascript) for a form timer in PHP?

0 Cevap