disabling/enabling the form values in php based on the if condition on the same page
<p>here what i want to do is based on the if condition's value the total form should be disabled, how can i do that, here is the code i tried....</p>

<pre><code>if ($today1 &gt;= $saturday &amp;&amp; $today1 &lt;= $season1)
    {
     document.getElementById('season').disabled = false;
    }
    else if($today1 &gt;= $startdate_offseasona1 &amp;&amp; $today1 &lt;= $enddate_offseasona1 )
    {
    document.getElementById('season').disabled = true;
    }
    else if($today1 &gt;= $startdate_seasona2 &amp;&amp; $today1 &lt;= $season2)
    {
    document.getElementById(seasons).disabled = false;
    } 
</code></pre>

<p>and my form goes as follows:</p>

<pre><code>&lt;form action="" method="POST" id="season" name="season"&gt;
Min_Custom_League_size&lt;input type="text" name="min_custom_league_size" size="40"/&gt;&lt;br/&gt;
Max_Custom_League_size:&lt;input type="text" name="max_custom_league_size" size="40"/&gt;&lt;br/&gt;
Ranked_League_size:&lt;input type="text" name="ranked_league_size" size="40"/&gt;&lt;br/&gt;
Screen_Capacity:&lt;input type="text" name="screen_capacity" size="40"/&gt;&lt;br/&gt;
Wide_Release_Screens:&lt;input type="text" name="wide_release_screens" size="40"/&gt;&lt;br/&gt;
Limited_Release_Screens:&lt;input type="text" name="limited_release_screens" size="40"/&gt;&lt;br/&gt;
Starting_Auction_Budget:&lt;input type="text" name="starting_auction_budget" size="40"/&gt;&lt;br/&gt;
Weekly_Auction_Allowance:&lt;input type="text" name="weekly_auction_allowance" size="40"/&gt;&lt;br/&gt;
Minimum_Auction_Bid:&lt;input type="text" name="minimum_auction_bid" size="40"/&gt;&lt;br/&gt;
&lt;input type="submit" value="submit" name="submit" /&gt;
&lt;/form&gt;
</code></pre>

<p>how can i do this based on the if condition value...what's wrong with my code??</p>
