
function wtslog(uid,dbn,ssl,page_name,invisible,text_counter){


   if (! page_name || page_name == '#'){
      page_name = '';
   }

   if (! invisible || invisible == '#'){
      invisible = '';
   }

   if (! text_counter || text_counter == '#'){
      text_counter = 'no';
   }

   if (ssl == 'https'){
      var prefix = 'https://www.compteur.fr';
   }
   else {
      if (dbn == 1){
         var prefix = 'http://www.compteur.fr';
      }
      else {
         var prefix = 'http://www.compteur.fr';
      }
   }

   try{var wtsb=top.document;var wtsr=wtsb.referrer;var wtsu=wtsb.URL;}
   catch(e){var wtsb=document;var wtsr=wtsb.referrer;var wtsu=wtsb.URL;}

   var qry= uid+':'+dbn+'::'+escape(wtsr)+'::'
+screen.width+'x'+screen.height+'::'+screen.colorDepth+'::'
+escape(page_name)+'::'+invisible+'::'+Math.random()+'::'+escape(wtsu);

   if (text_counter == 'yes' || text_counter == 'no_count'){
      document.write('<script language="JavaScript" src="'+prefix+'/count_text.pl?'+qry+'::'+text_counter+'"></script>');

   }
   else {

      document.write('<a href="http://www.compteur.fr/stats/'+uid+'.htm" ');
      document.write('target="new"><span id="mydiv" style="text-decoration:none;"><img id="count" src="'+prefix+'/count.pl?');

      if (invisible == 'yes'){
         document.write(qry+'" border="0" width="0" height="0" alt="site statistics"></span><\/a>');
      }
      else {
         document.write(qry+'" border="0" alt="compteur web"></span><\/a>');
      }

   }



}



