lp_ajax_start_timer.php 545 B

123456789101112131415161718192021
  1. <?php
  2. /* For licensing terms, see /license.txt */
  3. use Chamilo\CoreBundle\Framework\Container;
  4. /**
  5. * @package chamilo.learnpath
  6. * @author Yannick Warnier <ywarnier@beeznest.org>
  7. */
  8. /**
  9. * Start a timer and hand it back to the JS by assigning the current time (of start) to
  10. * var asset_timer
  11. * @return string JavaScript time intializer
  12. */
  13. function start_timer() {
  14. $time = time();
  15. return $time; //"olms.asset_timer='$time'; olms.asset_timer_total = 0;";
  16. }
  17. echo start_timer();
  18. Container::$legacyTemplate = 'layout_empty.html.twig';