Why is this ASP Script not working?
<p>Could you tell me whats wrong with this ASP script:</p>

<p>I think the error is in the <code>if</code> statement</p>

<pre><code>&lt;script&gt;
productID=new Array()
variaveis=location.search.replace(/\x3F/,"").replace(/\x2B/g," ").split("&amp;")
if(variaveis!=""){
for(i=0;i&lt;variaveis.length;i++){
nvar=variaveis[i].split("=")
productID[nvar[0]]=unescape(nvar[1])
}
}
function QueryString(variavel){
return productID[variavel]
}
document.writeln (QueryString("c"));
var flash = (QueryString("c"));
if (flash = "flash1") 
{
document.write("&lt;b&gt;flash1&lt;/b&gt;");
}
else if (flash = "flash2")
{
document.write("&lt;b&gt;flash2&lt;/b&gt;");
}
else
{
document.write("&lt;b&gt;another&lt;/b&gt;");
}
&lt;/script&gt;
</code></pre>
