Trouble with refreshing countdown in javascript
<p>I have countdown on my <a href="http://project-welcome.ugu.pl/a.php" rel="nofollow">site</a> which fails to refresh itself.</p>

<p>Code: <a href="http://pastebin.com/DNjb0WSN" rel="nofollow">http://pastebin.com/DNjb0WSN</a></p>

<pre><code>window.onload = function() {
    idElement = "time";
    document.getElementById(idElement).innerHTML = 
        "&lt;?php countdown(21,00,00,9,15,2012) ?&gt;";

    setInterval("document.getElementById(idElement).innerHTML = 
        '&lt;?php countdown(21,00,00,9,15,2012) ?&gt;'", 1000);
};

// ...

&lt;?php
    function countdown($godzina, $minuta, $sekunda, $miesiac, $dzien, $rok) {
        $target = mktime($godzina, $minuta, $sekunda, $miesiac, $dzien, $rok);
        $now = time();
        $sekundy = ($target - $now);
        // $sekundy =(int) ($sekundy) ;

        $check = 0;
        if ($sekundy &gt; 0) {
            if ($check == 0) {
                if ($sekundy &lt;= 10000) {
                    // zmien klase
                    $check = 1;
                }
            }
            $hours = floor($sekundy / 3600);
            $minutes = floor(($sekundy / 60) - ($hours * 60));
            $seconds = floor(($sekundy) - ($hours * 3600) - ($minutes * 60));


            if ($hours &lt; 10) $hours = '0'.$hours;

            if ($minutes &lt; 10) $minutes = '0'.$minutes;

            if ($seconds &lt; 10) $seconds = '0'.$seconds;

            $all = $hours." : ".$minutes." : ".$seconds;
            echo $all;
        }
        else {
            echo "Aukcja zakończona!";
        }
    }
?&gt;
</code></pre>

<p><br>Why it doesn't work?</p>
