I am using WordPress 3..5 on Dreamhost, trying to produce a text widget within the sidebar which will show a random group of nine (9) client logos. You will find a maximum of 12 logos, situated within the /wordpress-content/clients folder, named logo1.digital through logo12.digital.
The concept is to find the first image at random, then obtain the next eight images in consecutive to avoid replicates.
First got it working, just tips everybody!
This is actually the final, working version:
document.write() runs prior to the page finishes loading.. you need to use another thing..
to begin with, you need to get object of the div container by id:
<div id="containerid"></div> <script> var elem = document.getElementById('containerid'); elem.innerHTML= "FirstPart + r + LastPart"; </script>
t<8 and delay pills work (for me personally). The 2nd expression inside a
for loop means: "Execute the foor loop as lengthy because this is true". Your code needs to be performed as lengthy as
t < 8 when
t == 8, it will stop.
Working example: http://jsfiddle.net/m7m7C/