Javascript ... Displaying Values
<p>I'm creating a blackjack card game in Javascript.  I appreciate your comments so far.
I'm looking for feedback as to why I can only seem to call the cardFace function once within the cardDealer function. At present cardFace(0) gives me a value whereas cardFace(1) or any other number does not UNLESS it is the only cardFace(x) being called within the cardDealer function.  Any ideas would be appreciated.  Thanks </p>

<p>Code below is not complete but I believe enough to discern enough information from.  Thanks       </p>

<pre><code>    function card(name, suit, face, value)
    {
        this.name = name;
        this.suit = suit;
        this.face = face;
        this.value = value;
    }

    aceOfHearts = new card("aceofhearts","hearts", "ace", 11);
    kingOfHearts = new card("kingofhearts","hearts", "king", 10);
    queenOfHearts = new card("queenofhearts","hearts", "queen", 10);
    jackOfHearts = new card("jackofhearts","hearts", "jack", 10);
    tenOfHearts = new card("tenofhearts","hearts", "ten", 10);
    nineOfHearts = new card("nineofhearts","hearts", "nine", 9);
    eightOfHearts = new card("eightofhearts","hearts", "eight", 8);
    sevenOfHearts = new card("sevenofhearts","hearts", "seven", 7);
    sixOfHearts = new card("sixofhearts","hearts", "six", 6);


    var deck;
    deck = [];


    deck.push(aceOfHearts);
    deck.push(aceOfDiamonds);
    deck.push(aceOfClubs);
    deck.push(aceOfSpades);
    deck.push(kingOfClubs);
    deck.push(kingOfDiamonds);
    deck.push(kingOfHearts);
    deck.push(kingOfSpades);
    deck.push(queenOfClubs);
    deck.push(queenOfDiamonds);
    deck.push(queenOfHearts);
    deck.push(queenOfSpades);
    deck.push(jackOfClubs);
    deck.push(jackOfDiamonds);
    deck.push(jackOfHearts);
    deck.push(jackOfSpades);
    deck.push(tenOfClubs);
    deck.push(tenOfDiamonds);
    deck.push(tenOfHearts);
    deck.push(tenOfSpades);


    var cardDealer = function()
    {  
        fisherYates(deck);

        document.getElementById("yourFirstCard").textContent = "Your First Card is " + cardFace(0) ;
        document.getElementById("yourSecondCard").textContent = "Your Second Card is " + cardFace(1) ;

    };

    var cardFace = function(x)
    {   
        cardFace = deck[x].face;
        return cardFace;
    };


    var cardSuit = function(x)
    {
        cardSuit = deck[x].suit;
        return cardSuit;
    };

    &lt;body&gt;
&lt;div&gt;Black Jack 1.1&lt;/div&gt;
&lt;br/&gt;
&lt;button type="button" onClick="cardDealer()"&gt;Deal&lt;/button&gt; 
&lt;div id="yourFirstCard"&gt;&lt;/div&gt;
&lt;div id="yourSecondCard"&gt;&lt;/div&gt;
&lt;div id="yourThirdCard"&gt;&lt;/div&gt;
&lt;div id="yourFourthCard"&gt;&lt;/div&gt;
&lt;div id="yourFifthCard"&gt;&lt;/div&gt;
&lt;div id="playerTotal"&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div id="playerSit"&gt;&lt;/div&gt;
&lt;div id="playerMessage"&gt;&lt;/div&gt;
&lt;div id="sitter"&gt;&lt;button type="button" onClick="sit()"&gt;Sit&lt;/button&gt;&lt;/div&gt;
&lt;div id="hitter"&gt;&lt;button type="button" onClick="hitMe()"&gt;Hit&lt;/button&gt;&lt;/div&gt; 
&lt;br/&gt;
&lt;br/&gt;
&lt;div id="dealersFirstCard"&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div id="dealersSecondCard"&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div id="dealersThirdCard"&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div id="dealersFourthCard"&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div id="dealersFifthCard"&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div id="dealerTotal"&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div id="dealerSit"&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div id="dealerMessage"&gt;&lt;/div&gt;&lt;/div&gt;
&lt;/body&gt;
</code></pre>
