Clicking a button and having message output and new page opened based on set values in check b
<p>I have 4 drop down lists on my page. Im trying to output a message and then open up a new page on the click of a submit button. This is based on the condition of a single value of each drop down list being true. all the options of each check list being true. For example 50p=true, in the next box £2 equals true and so on for each list.</p>

<p>Here is an example of one of the boxes. The other 3 boxes have the exact same names but just have different true and false values</p>

<pre><code>&lt;input name="button" type="submit" class="main" id="button" value="Submit" onclick="submit()" /&gt;

&lt;select name="select_box" size="1" class="main" id="select_box"&gt;
&lt;option value="true"&gt;50p&lt;/option&gt;
&lt;option value="false"&gt;1p&lt;/option&gt;
&lt;option value="false" selected="selected"&gt;20p&lt;/option&gt;
&lt;option value="false"&gt;£2&lt;/option&gt;
&lt;/select&gt;
</code></pre>

<p>This is where ive had an attempt at trying to assign variables. My logic was if i could assign variables to the names of the drop down lists by getting their id i could apply an if statement that would give me the desired outcome based on the onclick funtion, as the select boxes have true and false values in them ? When i run this code Javascript only seems to acknowledge and call up the alert box regardless of the options, its as if there is no other code there.   </p>

<pre><code>var a=document.getElementById("select_box");
var b=document.getElementById("select_box2");
var c=document.getElementById("select_box3");
var d=document.getElementById("select_box4");

object.onclick=submit
if (a=true,b=true,c=true,d=true)
{
alert("Correct you have won press OK for your Reward!")
document.open("Reward.html");
}
else
{
alert("Not right Please try again!");
}
</code></pre>

<p>Also how do I apply the above mentioned submit button to work these statements   </p>

<p>I apologise for the poor editing at the top of the first half of the code im not too sure how to editi it so the rest of the words show</p>
