function rotacionar(prefixo,total) {

   for(var x = 0; x <= total; x++) {

         var lay = document.getElementById(prefixo + x);

         if(lay.style.display == '')
         {
             lay.style.display = 'none';

             if(x == total)
                 x = 0;
             else
                 x++;

             var lay = document.getElementById(prefixo + x);
             if(lay.style.display == 'none')
             {
                 lay.style.display = '';
             }

         }

     }

 }

