Drop down value setting

Posted by Harish on Stack Overflow See other posts from Stack Overflow or by Harish
Published on 2010-04-01T10:28:32Z Indexed on 2010/04/01 10:33 UTC
Read the original article Hit count: 248

Filed under:
|

Whenever a new window is opened and the drop value by default is 'yyyy'(For eg: yyyy for years), onclick of the drop down the value should automatically change to current year, which will be one of the values in the dropdown list (any place in the drop down). So now the value will be set to the current year. Again if the user clicks on the dropdown, the user can change the value to any(For eg: select 'yyyy'). So now the value set in drop down is 'yyyy'. condition 3, if the user clicks on the drop down since the value is 'yyyy' , focus should be the current year and also the value automatically. Please give the sloution for the mentioned requirement????

© Stack Overflow or respective owner

Related posts about dropdown

Related posts about default-value