~dont_cache() ~includeonce('../config.tmpl') ~set('title',"~get('website_title'): les votes sur le sondage") ~set('meta_robots','noindex,follow') ~include('../site/header.tmpl')
~include('../box/submit.tmpl')

Vous avez une meilleure idée de sondage ? Envoyez-la nous.

~list(~get('database'), 'SELECT COUNT(id) AS count FROM poll_questions', 'LM', ~set('num',~fld('count')) ) ~include('../site/next_page.tmpl',~get_filenamevar(1),~get('num'),20,'index') ~list(~get('database'), "SELECT id, question FROM poll_questions ORDER BY id DESC LIMIT 20 OFFSET ~get('indice')",'LM','

~fld('question')

~set('total_votes', ~list(~get('database'),"SELECT SUM(number) AS sum FROM poll_answers WHERE question_id='~fld('id')'","LM",~fld('sum'))) ~list(~get('database'),"SELECT answer, number FROM poll_answers WHERE question_id='~fld('id')' ORDER BY answer_nb",'LM','
  • ~fld('answer') :
    ~fld('number')
    (~round(100*~fld('number')/~get('total_votes'),1)%)
')

Total : ~get('total_votes') votes

> Lire les commentaires. ~include('../site/countcomments.tmpl',~fld('id'),~get('res_type_poll'))

','LD','Pas de sondage') ~include('../site/next_page.tmpl',~get_filenamevar(1),~get('num'),20,'index')
~include('../site/footer.tmpl')