document.write('\
');document.write('
\
');
var cpt_7679 = new Array();
var limite_cpt_7679 = new Array();
var limite_type_7679 = new Array();
var num_quest_7679 = new Array();
cpt_7679[42834] = 0;
limite_cpt_7679[42834] = 0;
limite_type_7679[42834] = 'max';
num_quest_7679[42834] = 1;
cpt_7679[42835] = 0;
limite_cpt_7679[42835] = 0;
limite_type_7679[42835] = 'max';
num_quest_7679[42835] = 2;
cpt_7679[42836] = 0;
limite_cpt_7679[42836] = 0;
limite_type_7679[42836] = 'max';
num_quest_7679[42836] = 3;
cpt_7679[42837] = 0;
limite_cpt_7679[42837] = 0;
limite_type_7679[42837] = 'max';
num_quest_7679[42837] = 4;
cpt_7679[42838] = 0;
limite_cpt_7679[42838] = 0;
limite_type_7679[42838] = 'max';
num_quest_7679[42838] = 5;
cpt_7679[42839] = 0;
limite_cpt_7679[42839] = 0;
limite_type_7679[42839] = 'max';
num_quest_7679[42839] = 6;
cpt_7679[42840] = 0;
limite_cpt_7679[42840] = 0;
limite_type_7679[42840] = 'max';
num_quest_7679[42840] = 7;
function sondage_pager7679(direction)
{
var active_question = 0;
for(i = 0 ; i < 7 ; i ++)
{
if(document.getElementsByClassName('contenu7679')[i].style.display == 'block')
{
active_question = i;
break;
}
}
if(direction == 'next')
{
active_question ++;
if(active_question > 6)
{
active_question = 6;
}
document.getElementsByClassName('pager-link7679')[0].style.display = 'inline-block';
document.getElementsByClassName('pager-link7679')[1].style.display = 'inline-block';
if(active_question == 6)
{
document.getElementsByClassName('pager-link7679')[1].style.display = 'none';
document.getElementsByClassName('bouton7679')[0].style.display = 'none';
document.getElementsByClassName('bouton7679')[1].style.display = 'block';
}
}
else
{
active_question --;
if(active_question < 0)
{
active_question = 0;
}
document.getElementsByClassName('pager-link7679')[0].style.display = 'inline-block';
document.getElementsByClassName('pager-link7679')[1].style.display = 'inline-block';
if(active_question == 0)
{
document.getElementsByClassName('pager-link7679')[0].style.display = 'none';
}
}
for(i = 0 ; i < 7 ; i ++)
{
if(i == active_question)
{
document.getElementsByClassName('contenu7679')[i].style.display = 'block';
}
else
{
document.getElementsByClassName('contenu7679')[i].style.display = 'none';
}
}
}
function compter7679(cb, idq)
{
if(cb.type == 'checkbox')
{
if(cb.checked == true)
{
cpt_7679[idq] ++;
}
else
{
cpt_7679[idq] --;
}
}
else if(cb.type == 'radio')
{
if(cb.checked == true)
{
cpt_7679[idq] = 1;
}
else
{
cpt_7679[idq] = 0;
}
}
}
function formSubmit7679()
{
msg1 = msg2 = '';
for(idq in cpt_7679)
{
if(cpt_7679[idq] == 0)
{
msg2 = 'Veuillez r\351pondre \340 toutes les questions !';
break;
}
else if(limite_type_7679[idq] == 'max' && limite_cpt_7679[idq] > 0 && cpt_7679[idq] > limite_cpt_7679[idq])
{
msg1 += '- Veuillez ne pas cocher plus de ' + limite_cpt_7679[idq] + ' r\351ponses pour la question num\351ro ' + num_quest_7679[idq] + ' !\n';
}
else if(limite_type_7679[idq] == 'exact' && limite_cpt_7679[idq] > 0 && cpt_7679[idq] != limite_cpt_7679[idq])
{
msg1 += '- Veuillez cocher ' + limite_cpt_7679[idq] + ' r\351ponses pour la question num\351ro ' + num_quest_7679[idq] + ' !\n';
}
}
if(msg2 != '')
{
alert(msg2);
return false;
}
else if(msg1 != '')
{
alert(msg1);
return false;
}
document.getElementById('formSondage7679').referer.value = document.location.href;
return true;
}
window.setTimeout('document.getElementById(\'formSondage7679\').reset()', 500);