title: calling dropdown dynamically for selecting date in html
body: <pre><code>  &lt;select  value="dt" name="previousYear"&gt;
    &lt;option value="2007"&gt;2007&lt;/option&gt;
    &lt;option value="2008"&gt;2008&lt;/option&gt;
    &lt;option value="2009"&gt;2009&lt;/option&gt;
    &lt;option value="2010"&gt;2010&lt;/option&gt;
    &lt;option selected="selected" value="2011"&gt;2011&lt;/option&gt;
    &lt;option value="2012"&gt;2012&lt;/option&gt;
    &lt;option value="2012"&gt;2013&lt;/option&gt;
    &lt;option value="2012"&gt;2014&lt;/option&gt;
  &lt;/select&gt;
  &lt;select  value="dt" name="currentYear"&gt;
    &lt;option value="2007"&gt;2007&lt;/option&gt;
    &lt;option value="2008"&gt;2008&lt;/option&gt;
    &lt;option value="2009"&gt;2009&lt;/option&gt;
    &lt;option value="2010"&gt;2010&lt;/option&gt;
    &lt;option selected="selected" value="2011"&gt;2011&lt;/option&gt;
    &lt;option value="2012"&gt;2012&lt;/option&gt;
    &lt;option value="2012"&gt;2013&lt;/option&gt;
    &lt;option value="2012"&gt;2014&lt;/option&gt;
  &lt;/select&gt;
  &lt;select  value="dt" name="nextYear"&gt;
    &lt;option value="2007"&gt;2007&lt;/option&gt;
    &lt;option value="2008"&gt;2008&lt;/option&gt;
    &lt;option value="2009"&gt;2009&lt;/option&gt;
    &lt;option value="2010"&gt;2010&lt;/option&gt;
    &lt;option selected="selected" value="2011"&gt;2011&lt;/option&gt;
    &lt;option value="2012"&gt;2012&lt;/option&gt;
    &lt;option value="2012"&gt;2013&lt;/option&gt;
    &lt;option value="2012"&gt;2014&lt;/option&gt;
  &lt;/select&gt;
  </code></pre>
  
  <p>I have 3 drop down list like this previous year ,current year &amp; next year How can i select the current year as a current year like if the current year is 2012 then it automatically have to select the 2012 when page loads can any one tell me the Javascript  code for selecting dynamikcally</p>