Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript array de imagenes

 function random_card(){
            if(cards.length > 0){
            var rand = Math.floor(Math.random()*cards.length);
            var html = "card: <img src='./img/"+cards[rand][0]+"' /><br/>points: "+cards[rand] [1]+"<br/><br/>";
            document.getElementById("myDiv").innerHTML += html;
            cards.splice(rand, 1);
            }
      }
Source by es.stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #javascript #array #de #imagenes
ADD COMMENT
Topic
Name
4+1 =