/* //==== dependance(statistics0) dependance(likes0) dependance(ipcount0) "E:\myproducts_sites\strangers\education\build\jslib\statistics0.js.php" */ function uPointerIdstatistics0(id){ //c return(document.getElementById(id)); if(id.substring(0,1)!='#')id='#'+id; ///return(document.querySelector('#' + idPlayer)); return(document.querySelector(id)); } function do_procedure_of_click_on_tdofbarmenu_for_ihm_cookie(){ var x=uPointerId('id_divinfocookies'); if(x)x.style.display='inline'; x=uPointerId('id_divcloseinfocookies'); if(x)x.style.display='inline'; } function do_procedure_of_click_on_consent_cookie_get_accept_array(what){ var arr; switch(what){ case 0: arr=new Array('trade0','publicity0','statistics0','-','trade1','publicity1','statistics1');break; case 1: arr=new Array('trade0','publicity0','statistics0','-','trade1','publicity1','statistics1');break; } return(arr); } function do_procedure_of_click_on_consent_cookie_for_all(id,tag){ var x;//c tag==cookieaccept if(id=='all'+tag){ var arr=do_procedure_of_click_on_consent_cookie_get_accept_array(1); var val=uPointerId('all'+tag).checked; for(var i=0;i id=ref:book/chap/test/num ///var ie=false; ///if(!event){event=window.event;ie=true;} //=== ////mode='questionsebook'; //c repquestradio //c ///alert('lj:126 statistics0.js.php repquestradio => '+uPointerId('repquestradio').value); ///alert('lj:127 statistics0.js.php solquestradio => '+uPointerId('solquestradio').value); ///alert('lj:128 statistics0.js.php coeffquestradio => '+uPointerId('coeffquestradio').value); var v=uPointerId('repquest'+num).value,pass='empty|empty|empty',r=uPointerId('displayresults'+referer),z=0,w='',n=''; if(id){ if(v=='') {alert('You must answer ! Thanks you.');return(false);} if(!confirm('Are you sure ?'))return(false); var x=uPointerId('questlist'+num).value.split(','),y=uPointerId('replist'+num).value.split(','), thenum=uPointerId('thenum'+num).value, t='',r,total=0,calc0=0,calc=0,totalquestion=0; ////alert('lj:130 statistics0.js.php y => '+y); for(var i=0;i1); } //=== ////alert('lj:135 statistics0.js.php repquest => '+uPointerId('repquest'+num).value); if(y[i]>0&&t){ z+=y[i]; /// n+=y[i]; ///z=(uPointerId('repquestradio').value-uPointerId('solquestradio').value==0?1:0); } }//c for(var i=0;i '+y); total=parseInt(wz.value); } ///alert('lj:160 statistics0.js.php y => '+y.value); if(r.innerHTML=='boot')r.innerHTML=''; if(r.innerHTML=='') r.innerHTML=total+'/'+alltotal+':'+z+':'+thenum+':'+totalquestion; else{ y=r.innerHTML.split(':'); r.innerHTML=total+'/'+alltotal+':'+y[1]+','+z+':'+y[2]+','+thenum+':'+y[3]+','+totalquestion; } z=uPointerId('spandisplayresults'+referer); z.style.display='inline'; z=r.innerHTML.split(':'); r.style.fontSize='8pt'; y=z[1].split(','); for(i=0;i '+x); w=r.innerHTML; if(z){ pass=z.value+'|'+uPointerId('doccode').value+'|'+uPointerId('docmail').value; if(id!='') createCookieebook('docpseudo',pass,7); else{ pass+='|'; ///alert('lj:185 statistics0.js.php pass => '+pass); } } if(w=='boot')r.innerHTML=''; //=== var mode='question_update',index=8; /* if(!fphp){ var fphp='a.functions.php'; var ftxt='a.ipcount.txt'; } */ ////alert('lj:191 statistics0.js.php r.innerHTML => '+fphp+' - '+ftxt); var arr=new Array('ip','count',mode,'',fphp,ftxt,'index;'+index+';;value;'+w+';;ref;'+referer+';;pwd;'+pass,jskebook,''); ////alert('lj:201 statistics0.js.php pass => '+pass); js_cmd_xhttpr(arr); }//c function do_procedure_of_click_on_response(event,id,num,pattern) //=== function do_procedure_ipcount_with_after_ajax_response(tab,response,result,resok){ //==== dependance(likes0) dependance(ipcount0) //c srvie=ip&cmd=count&mode=simple ///if(!resok)return(resok); if(tab['srvie']+tab['cmd']!='ipcount')return(false); var x=uPointerId('pseudomailcode'); if(x&&tab['mode']=='question_update'){ ///alert('lj:208 x tab[mode] result => '+x+' - '+tab['mode']+' - '+result); /* lj:58 result => 1, a.functions.php,,srvie=ip&cmd=count&mode=question_update&cod=&nor=undefined,,code_html,,20160919194625, nopwd,,5,,,,,,,,,,,,127.0.0.3,,,,nopwd,,,,0100 */ ////alert('lj:213 result[2] => '+result[2]+' - '+x.style.background); if(result[2]=='nopwd') x.style.background='red'; else x.style.background='green'; ////alert('lj:218 result => '+result+' - '+x.style.background); } //==== if(tab['mode']!='simple')return(false); // //==== if(result[4]){ ///alert('lj:58 result[4] => '+result[4]); do_procedure_likes_change_image(result[4]); do_procedure_consent_cookies_display(result[4]); } //==== var main_counter=uPointerId('main_counter'); if(!main_counter)return(false); var x=jsget_partsOfURL(),points=''; if(x.ext.substring(0,3)!='php'){ var tag='url('+jskebook+'/res/img/';///'../../../../images/design/'; points='../../'; x=result[3].split(tag); for(var i=0;i '+tab['mode']+' - result => '+result); /* lj:154 result => 1,a.functions.php,,srvie=cookies&cmd=consent&mode=cookiesconsent&cod=&nor=undefined,,poem,,20160818080817,a-111-111-20160818080817,,a-111-111-20160818080817 */ do_procedure_consent_cookies_display(result); ////alert('lj:167 tab[\'mode\'] => '+tab['mode']+' - result => '+result); } function do_procedure_cookiepref_with_after_ajax_response(tab,response,result,resok){ //==== dependance(likes0) dependance(ipcount0) //c srvie=ip&cmd=count&mode=simple if(tab['mode']!='simple')return(false); ///if(!resok)return(resok); if(tab['srvie']+tab['cmd']!='ipcount')return(false); //==== if(result[4]){ ///alert('lj:58 result[4] => '+result[4]); do_procedure_likes_change_image(result[4]); } ////alert('lj:60 jskebook => '+jskebook+' - result[3] => '+result[3] +' - result[4] => '+result[4]); //==== var main_counter=uPointerId('main_counter'); if(!main_counter)return(false); ///alert('lj:67 main_counter.innerHTML => '+main_counter.innerHTML); var x=jsget_partsOfURL(),points=''; if(x.ext.substring(0,3)!='php'){ var tag='url('+jskebook+'/res/img/';///'../../../../images/design/'; points='../../'; x=result[3].split(tag); for(var i=0;i '+result+' consentcookies => '+consentcookies); x=uPointerId('id_divinfocookies'); y=uPointerId('id_signalcookie'); z=uPointerId('id_hidden_imgsignalcookie'); if(consentcookies==''){ if(x)x.style.display='inline'; if(y){ y.style.backgroundImage='url()'; ///y.style.background='transparent'; //y.style.color='transparent'; } } else{ if(x)x.style.display='none'; if(y){ ////alert('lj:228 y.style.background.url => '+y.style.background.url+' z.value => '+z.value); /// y.style.background.url=z.value; y.style.backgroundImage='url('+z.value+')'; ///y.style.background='pink'; ///y.style.color='black'; } } } function do_procedure_likes_change_image(result){//c result[4] //==== dependance(likes0) dependance(ipcount0) //==== change image value var x=result.split(',,'),segment=x[0],idlikes=x[1],pattern=x[2]; //==== memo ///alert('lj:85 result => '+result+' pattern => '+pattern); var memo=idlikes+'_memo',m=uPointerIdstatistics0(memo); if(m&&m.value!='')m.value=segment;//c memo var idimg=uPointerIdstatistics0(idlikes); if(idimg){ var src=idimg.src; x=jsget_partsOfURL(src); /// alert('lj:96 src => '+src+' x.via => '+x.via+' segment => '+segment); if(parseInt(segment)<1)segment=5; var newsrc=x.via+'/'+pattern.replace('_x.','_'+segment+'.'); newsrc=newsrc.replace('_.','_'+segment+'.'); idimg.src=newsrc; ///alert('lj:85 result => '+result+' pattern => '+pattern); } } function do_procedure_likes_with_after_ajax_response(tab,response,result,resok){ //==== dependance(likes0) dependance(ipcount0) //c srvie=likes&cmd=site&mode=likesebook if(tab['srvie']+tab['cmd']!='likessite')return(false); if(tab['mode']!='likesebook')return(false); ///if(!resok)return(resok); if(result[2]=='!found')return(false); //==== if(result[4]){ ///alert('lj:112 result[4] => '+result[4]); do_procedure_likes_change_image(result[4]); } }