~dont_cache() ~includeonce('../config.tmpl') ~set('title','~get('website_title') : Concours') ~list( ~get('database'), "SELECT id FROM quizzes WHERE state=~get('state_ok') AND main=1 AND CURRENT_TIMESTAMP() >= start_timestamp AND CURRENT_TIMESTAMP() < end_timestamp ORDER BY id DESC LIMIT 1", 'LF',~setl('current_id',~fld('id')), 'LD',~redirect(~get_site_url()) ) ~if( ! ~integer(~get_filenamevar(1)), ~redirect('~get_site_url()concours/index,~getl('current_id').html') ) ~include('../updateuser.tmpl') ~include('../site/header.tmpl')