Can't load new url using if / else javascript statement - help?
<p>I've appropriated some code to create a countdown timer for the launch of a new site. The timer itself, which uses a custom typeface, works very well. </p>

<p>However, when the if / else statement for <code>timesup</code> is true and goes to 'else', I can't get any other function to work apart from the way you see it below:</p>

<pre><code>function formatresults(){
    if (this.timesup==false){//if target date/time not yet met
        var displaystring="&lt;div class='row'&gt;&lt;div class='col'&gt; "+arguments[0]+" &lt;/div&gt; &lt;div class='thincol'&gt;&amp;#149;&lt;/div&gt; &lt;div class='col'&gt; "+arguments[1]+" &lt;/div&gt; &lt;div class='thincol'&gt;&amp;#149;&lt;/div&gt;&lt;div class='col'&gt;  "+arguments[2]+" &lt;/div&gt; &lt;div class='thincol'&gt;&amp;#149;&lt;/div&gt; &lt;div class='col'&gt; "+arguments[3]+" &lt;/div&gt; &lt;/div&gt;"
    }
    else {
        var displaystring = "BAR"
    }
    return displaystring
}
</code></pre>

<p>if I change <code>var displaystring</code> to <code>window.location</code> (to load the full site at the end of the countdown), the timer ceases to work completely.</p>

<p>I know this is due to a fundamental misunderstanding of javascript in a way, but in all honesty I've developed sites using javascript and libraries like jquery and mootools and haven't hit a brick wall like this in a long time.</p>

<p>If you have any advice, please do share it with me!</p>

<p>Many thanks in advance</p>
