Else Statement for Null Variable
<p>I have this javscript that I wrote, and I want the "else" event to happen when bgimage does not equal 7.  I have looked into this issue and am unclear about how to check if the variable is null or not defined.  Currently, when bgimage does not equal 7, the Firebug just says "bgimage is not defined."</p>

<p>Thanks for teaching me how to do this in advance.</p>

<pre><code>if (bgimage == 7)
{
document.writeln("\n&lt;img src='/v/vspfiles/templates/donnell/images/Company/services_bg.jpg' id='bg' /&gt;");
}
else
{
showImage();
} 
</code></pre>
